Open RolfVeinoeSorensen opened 2 years ago
It may be related to "module": "es2020", Here is my tsconfig for the sake of completeness:
/* To learn more about this file see: https://angular.io/config/tsconfig. */
{
"compileOnSave": false,
"compilerOptions": {
"baseUrl": "./",
"outDir": "./dist/out-tsc",
"forceConsistentCasingInFileNames": true,
"strict": true,
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true,
"sourceMap": true,
"declaration": false,
"downlevelIteration": true,
"experimentalDecorators": true,
"moduleResolution": "node",
"importHelpers": true,
"target": "es2017",
"module": "es2020",
"lib": [
"es2018",
"dom"
],
"paths": {
"tslib" : ["node_modules/tslib/tslib.d.ts"],
"@app/*": ["src/app/*"],
"@shared/*": ["src/app/_shared/*"],
"@models/*": ["src/app/_models/*"],
"@helpers/*": ["src/app/_helpers/*"],
"@services/*": ["src/app/_services/*"],
"@environments/*": ["src/environments/*"],
"@user/*": ["src/app/user/*"]
},
},
"angularCompilerOptions": {
"enableI18nLegacyMessageIdFormat": false,
"strictInjectionParameters": true,
"strictInputAccessModifiers": true,
"strictTemplates": true
}
}
I'm submitting a ... (check one with "x")
Current behavior Getting an error when trying to add ngx-datatable to my latest angular 12 project.
swimlane-ngx-datatable.js:formatted:1 Uncaught TypeError: (0 , tslibWEBPACK_IMPORTED_MODULE_6.decorate) is not a function at Module.600 (swimlane-ngx-datatable.js:formatted:1) at __webpack_require (bootstrap:19) at Module.6747 (app.component.ts:8) at webpack_require (bootstrap:19) at Module.4431 (environment.ts:19) at webpack_require (bootstrap:19) at webpack_exec (log$:23) at log$:23 at Function.webpack_require.O (chunk loaded:23) at log$:23
I have set in tsconfig "importHelpers": true, "noEmitHelpers": false,
Expected behavior
ngx-datatable should load
Reproduction of the problem ng new test-datatabe add "@swimlane/ngx-datatable": "^20.0.0" to package,json
add NgxDatatableModule to app.module
https://stackblitz.com/edit/angular-ivy-ovw2bh
What is the motivation / use case for changing the behavior?
Please tell us about your environment: Windows 10 Visual Studio Code
20.0.0
~12.2.0
all