❓module declaration error.
Could not find a declaration file for module '@editorjs/Header'. 'D:/wap/ANGULAR/editorjs/node_modules/@editorjs/header/dist/bundle.js' implicitly has an 'any' type.
Try npm i --save-dev @types/editorjs__header if it exists or add a new declaration (.d.ts) file containing declare module '@editorjs/Header';ts(7016)
import Header from '@editorjs/Header';
While I tried to build using ng build I found this error. How to solve this problem in angular?
you can add @ts-ignore comment above import
// @ts-ignore
import Header from '@editorjs/Header';
// ./types/types.d.ts
declare module "@editorjs/header"
// tsconfig.json
{
// ...
"typeRoots": ["./node_modules/@types", "./types"]
}
Same problem, except for list (was able to manually install typing for the Header). I know I can ignore (or mock) it, but it would be nice to actually have that type info. Is that coming?
you can add @ts-ignore comment above import
// @ts-ignoreimport Header from '@editorjs/Header';
it worked for me thanks
// ./types/types.d.ts declare module "@editorjs/header"// tsconfig.json { // ... "typeRoots": ["./node_modules/@types", "./types"] }
worked for me