CaliStyle / ng-intercom

Angular 7+ Wrapper for Intercom.com
MIT License
54 stars 46 forks source link

Please ensure your intercomSettings object is formatted correctly: Missing App ID. #86

Closed eyalhakim closed 4 years ago

eyalhakim commented 5 years ago

Versions

Description

A warning is thrown despite everything working correctly: Please ensure your intercomSettings object is formatted correctly: Missing App ID.

I spoke to Intercom and they confirmed they do not see this error on their logs.

alexyoungs commented 5 years ago

I've also just started seeing this having had it working for a while.

JohnnyTMD commented 5 years ago

I've also just started seeing this and it appeared without touching any intercom related code.

scott-wyatt commented 5 years ago

@eyalhakim can you put the output from the console in the issue?

scott-wyatt commented 5 years ago

This appears to be a change from Intercom, nothing we can really do here until intercom publishes their updated documentation.

eyalhakim commented 5 years ago

@scott-wyatt here is the output: `frame.b9364e05.js:1 Please ensure your intercomSettings object is formatted correctly: Missing App ID.

safeConsoleWarn @ frame.b9364e05.js:1

t.createOrUpdateUser @ frame.b9364e05.js:1

t.createOrUpdateUser @ frame.b9364e05.js:1

update @ frame.b9364e05.js:1

(anonymous) @ frame.b9364e05.js:1

processApiQueue @ frame.b9364e05.js:1

(anonymous) @ frame.b9364e05.js:1

p @ frame.b9364e05.js:1

(anonymous) @ frame.b9364e05.js:1

p @ frame.b9364e05.js:1

(anonymous) @ frame.b9364e05.js:1

p @ frame.b9364e05.js:1

m @ frame.b9364e05.js:1

(anonymous) @ frame.b9364e05.js:1

(anonymous) @ frame.b9364e05.js:1 `

alexyoungs commented 5 years ago

Solved this for now by removing ng-intercom, adding the intercom snippet to index.html and using the following in app.component:

(<any>window).Intercom(‘boot’, { app_id: *** });

Further to this, I subscribed to the current logged in user as well as router events to handle page changes and sending user details, by calling the following: (<any>window).Intercom('update', { email: 'email@here.com' ... etc });

Shut down intercom by calling:

(<any>window).Intercom('shutdown');

Seems to work.

I have wrapped this all in a service, but I hope this helps anyone in a similar situation whilst this module is being updated.

danielhusar commented 5 years ago

Sorry guys sorry for breaking this! Simply adding window.intercomSettings with appId will remove the warning.

I will remove the warning meanwhile to avoid any false positives.

scott-wyatt commented 5 years ago

Thanks @danielhusar, we will add window.intercomSettings to the source and push as soon as possible.