solid-markdown icon indicating copy to clipboard operation
solid-markdown copied to clipboard

Syntax Error. The requested module '....' does not provide an export named 'default

Open 1moeses opened this issue 9 months ago • 5 comments

I don't know what's going on, but on a solid start project of mine, since 2.0.2, I get the following error: The requested module '/_build/node_modules/.pnpm/[email protected]/node_modules/debug/src/browser.js?v=d23bb9d6' does not provide an export named 'default' If you need more information about the repo, please let me know and I'll try to help. With 2.0.1 everything still works fine.

This is my package.json

{
  "name": "test",
  "version": "0.0.0",
  "type": "module",
  "description": "",
  "scripts": {
    "dev": "vinxi dev",
    "build": "vinxi build",
    "start": "vinxi start",
    "lint": "eslint ./src --fix"
  },
  "dependencies": {
    "@solid-primitives/presence": "^0.0.6",
    "@solidjs/router": "^0.13.3",
    "@solidjs/start": "1.0.0-rc.0",
    "@types/js-cookie": "^3.0.6",
    "clsx": "^2.1.1",
    "js-cookie": "^3.0.5",
    "solid-js": "^1.8.17",
    "solid-markdown": "^2.0.3",
    "solid-slider": "^1.3.17",
    "tailwind-merge": "^2.2.2",
    "vinxi": "^0.3.11"
  },
  "engines": {
    "node": ">=18"
  },
  "devDependencies": {
    "@typescript-eslint/eslint-plugin": "^7.8.0",
    "@typescript-eslint/parser": "^7.8.0",
    "autoprefixer": "^10.4.19",
    "eslint": "^8.57.0",
    "eslint-config-airbnb-base": "^15.0.0",
    "eslint-config-airbnb-typescript": "^18.0.0",
    "eslint-config-prettier": "^9.1.0",
    "eslint-import-resolver-typescript": "^3.6.1",
    "eslint-plugin-import": "^2.29.1",
    "eslint-plugin-prettier": "^5.1.3",
    "eslint-plugin-solid": "^0.13.2",
    "eslint-plugin-unused-imports": "^3.2.0",
    "postcss": "^8.4.38",
    "prettier": "^3.2.5",
    "prettier-plugin-tailwindcss": "^0.5.14",
    "tailwindcss": "^3.4.3",
    "typescript": "~5.4.5",
    "vite": "^5.2.11"
  }
}

Screenshot 2024-05-08 at 23 07 19 Screenshot 2024-05-08 at 23 07 13

1moeses avatar May 08 '24 21:05 1moeses

somone else reported this error too, i'm looking into it, will let you know :D

andi23rosca avatar May 10 '24 14:05 andi23rosca

I think I'm also getting something similar to this issue. I'm using Astro with a Tauri Rust application and only doing client-side rendering where SolidJS and your library is concerned.

Version 2.0.1 works for me, with version 2.0.3 I receive an error saying: "SyntaxError: Importing binding name 'default' cannot be resolved by star export entries". This issue completely prevents my SolidJS form from rendering on the page, so for now I'm rolling back versions.

image

CM-IV avatar May 12 '24 00:05 CM-IV

I am using vanilla Solid with no meta-frameworks and also still facing the same issue.

RichDom2185 avatar May 26 '24 14:05 RichDom2185

It's was not really a good idea to update major dependency version on a patch version :-(

YvesZelros avatar May 31 '24 19:05 YvesZelros

Seems like the issue is with one of the dependencies I bumped. @YvesZelros has a good point, I should've bumped the minor or major version up instead of the patch.

I reverted the version upgrades for now in v2.0.12 of solid-markdown, it should work again.

Haven't found a fix for the import issue yet, but I'll update to 3.0.0 when I do and I can bump the deps again

andi23rosca avatar Jun 03 '24 13:06 andi23rosca