App.Component.ts:
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { GridModule } from '@syncfusion/ej2-angular-grids';
import { PageService } from '@syncfusion/ej2-angular-grids';
import { AppComponent } from './app.component';
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule, GridModule
],
providers: [PageService],
bootstrap: [AppComponent]
})
App.Module.ts:export class AppModule { }
App.Module.ts:
"paths": { "@angular/*": [ "../node_modules/@angular/*" ] }
Finally i solved it,
I put this path in the compilerOptions section of tsconfig.app.json of the angular application:"paths": { "@angular/*": [ "../node_modules/@angular/*" ] }
Have the same issue. Have added path ("paths": { "@angular/*": [ "../node_modules/@angular/*" ] }) and "preserveSymlinks": true. Using *latest angular 11 and *latest syncfusion. "@syncfusion/ej2-angular-gantt": "18.3.52","@syncfusion/ej2-angular-grids": "18.3.53", "@syncfusion/ej2-angular-inputs": "18.3.53", "@syncfusion/ej2-angular-kanban": "^18.3.53", "@syncfusion/ej2-angular-navigations": "18.3.53", "@syncfusion/ej2-angular-popups": "18.3.52",Error:core.js:5967 ERROR Error: inject() must be called from an injection context at injectInjectorOnly (core.js:893) at ɵɵinject (core.js:903) at Module.ɵɵdirectiveInject (core.js:14648) at NodeInjectorFactory.GanttComponent_Factory [as factory] (ej2-angular-gantt.js:542) at getNodeInjectable (core.js:3503) at instantiateAllDirectives (core.js:9952) at createDirectivesInstances (core.js:9301) at ɵɵelementStart (core.js:14523)..
"paths": { "@angular/*": [ "./node_modules/@angular/*" ] }