Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moving from Dexie 3.2.5 to 4.0.1 creates webpack failure #1955

Closed
lesjames opened this issue Apr 8, 2024 · 5 comments
Closed

Moving from Dexie 3.2.5 to 4.0.1 creates webpack failure #1955

lesjames opened this issue Apr 8, 2024 · 5 comments

Comments

@lesjames
Copy link

lesjames commented Apr 8, 2024

In an existing project I'm currently using Dexie 3.2.5. I bumped the version to 4.0.1 in package.json. After npm install and running a serve with webpack I get the following error.

Error: File './src/tsconfig.json' not found.
    at Be (/node_modules/get-tsconfig/dist/index.cjs:3:9201)
    at ie (/node_modules/get-tsconfig/dist/index.cjs:3:10245)
    at le (/node_modules/get-tsconfig/dist/index.cjs:3:10975)
    at Object.Le [as getTsconfig] (/node_modules/get-tsconfig/dist/index.cjs:3:11080)
    at Object.ESBuildLoader (/node_modules/esbuild-loader/dist/index.cjs:65:36)
    at LOADER_EXECUTION (/node_modules/loader-runner/lib/LoaderRunner.js:132:14)
    at runSyncOrAsync (/node_modules/loader-runner/lib/LoaderRunner.js:133:4)
    at iterateNormalLoaders (/node_modules/loader-runner/lib/LoaderRunner.js:251:2)
    at /node_modules/loader-runner/lib/LoaderRunner.js:224:4
    at /node_modules/webpack/lib/NormalModule.js:920:15

I do not use Typescript in my project. If I go into /node_modules/dexie/ and remove tsconfig.json then I'm able to build and serve the project.

@lucaju
Copy link

lucaju commented Apr 9, 2024

Similar error (and I do use Typescript.)

It seems that the source of the error is on tsconfig.json on Dexie. It extends the config from a file that is not shipped with the library:

{
  "extends": "./src/tsconfig.json",
}

@dfahlander
Copy link
Collaborator

Thanks! I've seen it and it was resolved in 7131ade. A new version out soon.

@dfahlander
Copy link
Collaborator

Fixed in 4.0.2

@lucaju
Copy link

lucaju commented Apr 10, 2024

The error persists on v.4.0.2
Error: File './src/tsconfig.json' not found.

tsconfig.json still ships with the package and still makes reference to a file not on the package

{
  "extends": "./src/tsconfig.json",
}

dfahlander added a commit that referenced this issue Apr 10, 2024
@dfahlander dfahlander reopened this Apr 10, 2024
@dfahlander
Copy link
Collaborator

dfahlander commented Apr 10, 2024

Ah, .npmignore didn't swallow ./tsconfig.json. A new version 4.0.4 is out that should correct this. I checked in https://www.npmjs.com/package/dexie?activeTab=code that the tsconfig in the root is gone now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants