ng2-ace-editor
ng2-ace-editor copied to clipboard
It does not work with angular 8.0.0 and ivy enabled
when trying to build I got error, it is a stopper
WARNING in Entry point 'ng2-ace-editor' contains deep imports into 'brace/theme/monokai'. This is probably not a problem, but may cause the compilation of entry points to be out of order.
ERROR in node_modules/ng2-ace-editor/src/module.d.ts(1,22): error TS-996002: Appears in the NgModule.imports of AppModule, but could not be resolved to an NgModule class
I created a fork from this repo and upgraded it to Angular 9 , it should work
https://www.npmjs.com/package/ngx-ace-editor-wrapper
This is the exact same ng2-ace-editor just pumped to A9
Hello martinpagesaal, we use the 'ng2-ace-editor' aswell but got the same problems mentioned above after updating to angular 9 and enabling ivy. I tried to update to the 'ngx-ace-editor-wrapper' but I can't compile the project due to the following errors:
node_modules/ngx-ace-editor-wrapper/dist/src/directive.d.ts:37:18 - error TS2314: Generic type 'ɵɵFactoryDef' requires 2 type argument(s).
static ɵfac: i0.ɵɵFactoryDef<AceEditorDirective>; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ node_modules/ngx-ace-editor-wrapper/dist/src/component.d.ts:49:18 - error TS2314: Generic type 'ɵɵFactoryDef' requires 2 type argument(s).
static ɵfac: i0.ɵɵFactoryDef<AceEditorComponent>; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ node_modules/ngx-ace-editor-wrapper/dist/src/component.d.ts:50:18 - error TS2314: Generic type 'ɵɵComponentDefWithMeta' requires 7 type argument(s).
static ɵcmp: i0.ɵɵComponentDefWithMeta<AceEditorComponent, "ace-editor", never, { "style": "style"; "options": "options"; "readOnly": "readOnly"; "theme": "theme"; "mode": "mode"; "value": "value"; "text": "text"; "autoUpdateContent": "autoUpdateContent"; "durationBeforeCallback": "durationBeforeCallback"; }, { "textChanged": "textChanged"; "textChange": "textChange"; }, never>;
Same problem for me. I tried to update to 'ngx-ace-editor-wrapper' but I can't compile the project due to the above mentioned errors. @martinpagesaal
looks like it should compile correctly upgrading to angular 9.1 https://stackoverflow.com/questions/60898133/angular-9-ivy-generic-type-%C9%B5%C9%B5factorydef-requires-2-type-arguments
looks like it should compile correctly upgrading to angular 9.1 https://stackoverflow.com/questions/60898133/angular-9-ivy-generic-type-%C9%B5%C9%B5factorydef-requires-2-type-arguments
I followed the steps from the thread, but I still get the same errors. The only way to compile the project for now is to set "skipLibCheck":true in the tsconfig.json.
Had the same issue with angular 10.0.5 today when using https://www.npmjs.com/package/ngx-ace-editor-wrapper (see above). Just in case someone else has the same problem: I fixed it by making the following changes to the code:
node_modules/ngx-ace-editor-wrapper/dist/src/component.d.ts
:
static ɵfac: i0.ɵɵFactoryDef<AceEditorComponent, never>;
static ɵcmp: i0.ɵɵComponentDefWithMeta<AceEditorComponent, "ace-editor", never, { "style": "style"; "options": "options"; "readOnly": "readOnly"; "theme": "theme"; "mode": "mode"; "value": "value"; "text": "text"; "autoUpdateContent": "autoUpdateContent"; "durationBeforeCallback": "durationBeforeCallback"; }, { "textChanged": "textChanged"; "textChange": "textChange"; }, never, never>;
node_modules/ngx-ace-editor-wrapper/dist/src/directive.d.ts
:
static ɵfac: i0.ɵɵFactoryDef<AceEditorDirective, never>;
Hi guys, I made it work for my project and didn't went deeper into it.
this is how I'm using it right now, this is part of my package.json hope it helps
"dependencies": {
"@angular-devkit/schematics-cli": "^0.901.6",
"@angular/animations": "9.0.1",
"@angular/cdk": "9.0.0",
"@angular/common": "9.0.1",
"@angular/compiler": "9.0.1",
"@angular/core": "9.0.1",
"@angular/flex-layout": "^9.0.0-beta.29",
"@angular/forms": "9.0.1",
"@angular/material": "^9.0.0",
"@angular/material-moment-adapter": "9.0.0",
"@angular/platform-browser": "9.0.1",
"@angular/platform-browser-dynamic": "9.0.1",
"@angular/router": "9.0.1",
...
"ace-builds": "1.4.3",
...
"ngx-ace-editor-wrapper": "^9.0.1",
....
},