angular2-indexeddb icon indicating copy to clipboard operation
angular2-indexeddb copied to clipboard

Error when using with Angular 6.0

Open davidgallegolobato opened this issue 7 years ago • 7 comments

I got this error when using with angular 6.0:

ERROR in ./node_modules/angular2-indexeddb/index.ts Module build failed: Error: ....\ui\node_modules\angular2-indexeddb\index.ts is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property. The missing file seems to be part of a third party library. TS files in published libraries are often a sign of a badly packaged library. Please open an issue in the library repository to alert its author and askthem to package the library using the Angular Package Format (https://goo.gl/jB3GVv). at AngularCompilerPlugin.getCompiledFile (.....\ui\node_modules@ngtools\webpack\src\angular_compiler_plugin.js:708:23) at plugin.done.then (.......\ui\node_modules@ngtools\webpack\src\loader.js:41:31) at at process._tickCallback (internal/process/next_tick.js:188:7)

Thanks.

davidgallegolobato avatar May 17 '18 08:05 davidgallegolobato

Removing the .ts files from my local installation of the package made it work.

Is there any reason why the .ts files are distributed with the npm package?

davidgallegolobato avatar May 17 '18 09:05 davidgallegolobato

Also, having .ts files in the package does not work well with webpack's watch feature (so I have to remove them myself from the local installation folder as well).

sebastientromp avatar Jul 10 '18 12:07 sebastientromp

Will it be fixed?

mividedaninni avatar Aug 10 '18 13:08 mividedaninni

add the following code to tsconfig.app.json did the trick.

"include": [
    "../src/**/*",
    "../node_modules/angular2-indexeddb/index.ts",
    "../node_modules/angular2-indexeddb/angular2-indexeddb.ts",
  ]

chami007 avatar Aug 30 '18 14:08 chami007

Adding those files to the include causes linting to fail, as they don't pass lint standards. Please fix this soon.

rtaft avatar Dec 04 '18 14:12 rtaft

A temporary solution is to update your package.json and add the following to your scripts section: "postinstall": "rm node_modules/angular2-indexeddb/*.ts" This will delete the files after an npm install

rtaft avatar Dec 05 '18 17:12 rtaft

I have this same issue with angular 7.1.0

When will this be resolved?

Error: [redacted]\node_modules\angular2-indexeddb\index.ts is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property. The missing file seems to be part of a third party library. TS files in published libraries are often a sign of a badly packaged library. Please open an issue in the library repository to alert its author and ask them to package the library using the Angular Package Format (https://goo.gl/jB3GVv). at AngularCompilerPlugin.getCompiledFile ([redacted]\node_modules@ngtools\webpack\src\angular_compiler_plugin.js:719:23) at plugin.done.then ([redacted]\node_modules@ngtools\webpack\src\loader.js:41:31) at at process._tickCallback (internal/process/next_tick.js:188:7)

marcodafonseca avatar Mar 12 '19 14:03 marcodafonseca