You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An unhandled exception occurred: Error in config file! Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: <path-to>/karma.config.ts require() of ES modules is not supported. require() of <path-to>/karma.config.ts from /node_modules/karma/lib/config.js is an ES module file as it is a .ts file whose nearest parent package.json contains "type": "module" which defines all .ts files in that package scope as ES modules. Instead change the requiring code to use import(), or remove "type": "module" from package.json.
removing “type”: “module” from package.json gives below error
SyntaxError: Cannot use import statement outside a module
tried converting karma config file to .mjs and it below error
Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: /Users/ptalsani/Desktop/ui-kit-upgrade/ui-kit/projects/appd/common/karma.config.mjs
The text was updated successfully, but these errors were encountered:
I have recently upgraded to version 13 of angular. I’m able to build the project successfully but running tests gives the below issues,
Here is package.json dependencies
Below is the error while running the tests
An unhandled exception occurred: Error in config file! Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: <path-to>/karma.config.ts require() of ES modules is not supported. require() of <path-to>/karma.config.ts from /node_modules/karma/lib/config.js is an ES module file as it is a .ts file whose nearest parent package.json contains "type": "module" which defines all .ts files in that package scope as ES modules. Instead change the requiring code to use import(), or remove "type": "module" from package.json.
removing “type”: “module” from package.json gives below error
SyntaxError: Cannot use import statement outside a module
tried converting karma config file to .mjs and it below error
Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: /Users/ptalsani/Desktop/ui-kit-upgrade/ui-kit/projects/appd/common/karma.config.mjs
The text was updated successfully, but these errors were encountered: