Problem
When building an app using the ng-intercom library in production mode, the following error is thrown:
ERROR in /path/to/project/src/$$_gendir/node_modules/ng-intercom/intercom.module.ngfactory.ts (26,82): Argument of type '{}' is not assignable to parameter of type 'IntercomConfig'.
Property 'app_id' is missing in type '{}'.
This is due to the Intercom class being specified in both the module's providers and in the providers of the forRoot() method.
Solution
Only the forRoot() method should specify the Intercom class as a provider.
Problem When building an app using the ng-intercom library in production mode, the following error is thrown:
This is due to the
Intercom
class being specified in both the module's providers and in the providers of theforRoot()
method.Solution Only the
forRoot()
method should specify theIntercom
class as a provider.