How to use system js with Angular 14 and typescript
mrgopalakrishnan opened this issue · comments
mrgopalakrishnan commented
- SystemJS Version:
- Which library are you using?
- system.js
- s.js
- system-node.cjs
- Which extras are you using?
- AMD extra
- Named Exports
- Named Register
- Transform
- Use Default
- Global
- Dynamic Import Maps
- Are you using any custom hooks?
Question
How to use system js in Angular 14 with type script? i'm trying to import system js in angular as below.
"scripts": [
"node_modules/systemjs/dist/system.js"
]
And trying to set few modules in main.ts like below.
declare const SystemJS;
import * as angularCore from '@angular/core';
import * as angularCommon from '@angular/common';
SystemJS.set('@angular/core', SystemJS.newModule(angularCore));
SystemJS.set('@angular/common', SystemJS.newModule(angularCommon));
loong.woo commented
Modify SystemJS
to System
.