Closed philljones closed 6 years ago
OK, 1) I updated my CLI and NPM to the latest - just in case that might be the issue. 2) ran npm install -ng-intercom@latest -save
But I am still getting the same compile error.
I am running Angular 4.4.3 btw.
We have updated the package to support Angular 5 metadata. If your application is on v4, it will not work. I will push a new version to indicate that it requires a peer of v5.
ng-intercom now requires a peer of Angular >=5.0.0. You can use ng-intercom@1.0.0-beta.8
for the time being if you need 4.x.x support.
Thank you!
1) Deleting \node_modules\ng-intercom 2) npm install --save --save-exact ng-intercom@1.0.0-beta.8
... solved the issue for me on my Angular 4.4.3 version.
Thanks again.
Happy to help!
Hi - the instructions as written are not working for me.
$ npm install ng-intercom@beta --save <-- appears to be installing an alpha build that is not with the rest of the instructions:
IntercomModule.forRoot({ appId: "w0admjxc", updateOnRouterChange: true // will automatically run
update
on router event changes. Default:false
})appId and updateOnRouterChange through errors with this alpha build.
Updating to the latest beta 1.0.0-beta.9 gets eliminates these errors,
However, at compile time I get: ` ERROR in Error: Metadata version mismatch for module C:/Projects/VisualStudio/ppnsystem/Websites/VPortalNV10/node_modules/ng-intercom/dist/index.d.ts, found version 4, expected 3, resolving symbol AppModule in C:/Projects/VisualStudio/ppnsystem/Websites/VPortalNV10/src/app/app.module.ts, resolving symbol AppModule in C:/Projects/VisualStudio/ppnsystem/Websites/VPortalNV10/src/app/app.module.ts, resolving symbol AppModule in C:/Projects/VisualStudio/ppnsystem/Websites/VPortalNV10/src/app/app.module.ts at Error (native) at syntaxError (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler\bundles\compiler.umd.js:1729:34) at simplifyInContext (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler\bundles\compiler.umd.js:25111:23) at StaticReflector.simplify (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler\bundles\compiler.umd.js:25123:13) at StaticReflector.annotations (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler\bundles\compiler.umd.js:24553:41) at _getNgModuleMetadata (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler-cli\src\ngtools_impl.js:138:31) at _extractLazyRoutesFromStaticModule (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler-cli\src\ngtools_impl.js:109:26) at Object.listLazyRoutesOfModule (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler-cli\src\ngtools_impl.js:53:22) at Function.NgTools_InternalApi_NG_2.listLazyRoutes (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@angular\compiler-cli\src\ngtools_api.js:91:39) at AotPlugin._getLazyRoutesFromNgtools (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@ngtools\webpack\src\plugin.js:207:44) at _donePromise.Promise.resolve.then.then.then.then.then (C:\Projects\VisualStudio\ppnsystem\Websites\VPortalNV10\node_modules\@ngtools\webpack\src\plugin.js:443:24) at process._tickCallback (internal/process/next_tick.js:109:7)'
Any ideas what's going on here?