Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
- import { TranslateHttpLoader } from '@ngx-translate/http-loader';
- import { HttpClientModule, HttpClient } from '@angular/common/http';
- export const createTranslateLoader = (http: HttpClient) => {
- return new TranslateHttpLoader(http, './assets/i18n/', '.json');
- };
- TranslateModule.forRoot({
- loader: {
- provide: TranslateLoader,
- useFactory: createTranslateLoader,
- deps: [HttpClient]
- }
- }),
- ERROR in /home/practicas/projects/admin-panel/src/app/app.component.ts (17,3): Multiple constructor implementations are not allowed.
- ERROR in /home/practicas/projects/admin-panel/src/app/app.component.ts (28,3): Multiple constructor implementations are not allowed.
- ERROR in /home/practicas/projects/admin-panel/src/app/app.module.ts (4,9): Duplicate identifier 'HttpClientModule'.
- ERROR in /home/practicas/projects/admin-panel/src/app/app.module.ts (37,10): Duplicate identifier 'HttpClientModule'.
- ERROR in Error: Metadata version mismatch for module /home/practicas/projects/admin-panel/node_modules/@ngx-translate/core/core.d.ts, found version 4, expected 3, resolving symbol AppModule in /home/practicas/projects/admin-panel/src/app/app.module.ts, resolving symbol AppModule in /home/practicas/projects/admin-panel/src/app/app.module.ts, resolving symbol AppModule in /home/practicas/projects/admin-panel/src/app/app.module.ts
- at syntaxError (/home/practicas/projects/admin-panel/node_modules/@angular/compiler/bundles/compiler.umd.js:1729:34)
- at simplifyInContext (/home/practicas/projects/admin-panel/node_modules/@angular/compiler/bundles/compiler.umd.js:25111:23)
- at StaticReflector.simplify (/home/practicas/projects/admin-panel/node_modules/@angular/compiler/bundles/compiler.umd.js:25123:13)
- at StaticReflector.annotations (/home/practicas/projects/admin-panel/node_modules/@angular/compiler/bundles/compiler.umd.js:24553:41)
- at _getNgModuleMetadata (/home/practicas/projects/admin-panel/node_modules/@angular/compiler-cli/src/ngtools_impl.js:138:31)
- at _extractLazyRoutesFromStaticModule (/home/practicas/projects/admin-panel/node_modules/@angular/compiler-cli/src/ngtools_impl.js:109:26)
- at Object.listLazyRoutesOfModule (/home/practicas/projects/admin-panel/node_modules/@angular/compiler-cli/src/ngtools_impl.js:53:22)
- at Function.NgTools_InternalApi_NG_2.listLazyRoutes (/home/practicas/projects/admin-panel/node_modules/@angular/compiler-cli/src/ngtools_api.js:91:39)
- at AotPlugin._getLazyRoutesFromNgtools (/home/practicas/projects/admin-panel/node_modules/@ngtools/webpack/src/plugin.js:207:44)
- at _donePromise.Promise.resolve.then.then.then.then.then (/home/practicas/projects/admin-panel/node_modules/@ngtools/webpack/src/plugin.js:443:24)
- at <anonymous>
- at process._tickCallback (internal/process/next_tick.js:118:7)
Add Comment
Please, Sign In to add comment