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

Giving Error While Build #103

Open
mkamranaslam opened this issue Jun 21, 2022 · 1 comment
Open

Giving Error While Build #103

mkamranaslam opened this issue Jun 21, 2022 · 1 comment

Comments

@mkamranaslam
Copy link

Hi!
ngx-json-viewer@3.0.2 and @3.1.0 both are giving error when building with env, node v16.15.0 and npm v8.12.2.
When I downgrade the npm to v6.14.17 it works
`

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 200:12-19
Can't import the named export 'NgIf' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 279:10-18
Can't import the named export 'NgModule' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 169:12-30
Can't import the named export 'ɵɵFactoryTarget' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 250:12-30
Can't import the named export 'ɵɵFactoryTarget' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 210:0-27
Can't import the named export 'ɵɵngDeclareClassMetadata' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 273:0-27
Can't import the named export 'ɵɵngDeclareClassMetadata' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 171:45-68
Can't import the named export 'ɵɵngDeclareComponent' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 163:45-66
Can't import the named export 'ɵɵngDeclareFactory' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 244:42-63
Can't import the named export 'ɵɵngDeclareFactory' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 261:42-64
Can't import the named export 'ɵɵngDeclareInjector' from non EcmaScript module (only default export is available)

ERROR in ./node_modules/ngx-json-viewer/fesm2015/ngx-json-viewer.mjs 252:42-64
Can't import the named export 'ɵɵngDeclareNgModule' from non EcmaScript module (only default export is available)
`

@hivivo
Copy link
Owner

hivivo commented Jun 23, 2022

I created a new Angular 14 project by ng new, ran yarn add ngx-json-viewer and then yarn build. Everything looks good.

Do you mind sharing some snippet project to reproduce your issue?

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

2 participants