Comments (4)
import Intercom from 'react-intercom'
should solve this issue. I initially had { } around Intercom and had the same error.
from react-intercom.
I was able to set this up just now in a new application without any special configuration--in the setup process, they automatically moved me to the next phase when I refreshed my page after inserting the component.
Any additional context you can share that could reproduce this? Unfortunately it is kind of annoying to create new Intercom instances just to test this.
Anyways, marking as resolved.
from react-intercom.
@nhagen Just following up on this, so we shouldn't have to import Intercom from 'react-intercom'? A question around that is, then how does React know anything about the <Intercom .... /> component? I have react-intercom installed (package.json), however wiring the component just as per the instructions on the front page, no import in component, no script import. I have in my app <Intercom appID="my app id" {...user}/> when I do this I get the following issue warning/errors.Warning: i(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object. a.(anonymous function) invariant.js:44 Uncaught Error: i(...): A valid React element (or null) must be returned. You may have returned undefined, an array or some other invalid object.
from react-intercom.
Sorry, I'll add the import to the README to make it more clear. I am able to get past the verification step by simply importing the component as normal and use it in an application.
Can you provide an example of your code? That would help me understand if there's a specific way you're doing this that I haven't considered which doesn't work.
Edit: after updating the readme, I realize it wasn't apparent that the export you needed was the default export rather than a named export--if you're doing import { Intercom } from 'react-intercom'
, Intercom
will be undefined, possibly causing that error you're getting. It should be import Intercom from 'react-intercom'
from react-intercom.
Related Issues (20)
- Support for user_hash for Identify Verification HOT 1
- Intercom iframe mounting multiple times HOT 4
- customise the styling of intercom HOT 2
- Not able to use IntercomAPI HOT 2
- Receiving multiple 'rate_limited_update' errors in console HOT 8
- React 16.9 - Warning: componentWillReceiveProps has been renamed, and is not recommended for use. HOT 3
- 2.0 Refresh HOT 17
- Calls to Intercom('update') should be placed in effect not in render method HOT 2
- Thank you HOT 2
- Access to `Intercom('show');` Function HOT 2
- Create a hook in react-intercom 2.0 HOT 1
- Types for IntercomAPI HOT 3
- Please update to UNSAFE_* HOT 2
- Intercom API should take a method name and an object, not array. HOT 2
- user signout on unmount HOT 5
- react-dom.development.js:12449 Warning: componentWillReceiveProps has been renamed, and is not recommended for use HOT 2
- Unable to see intercom messenger HOT 3
- Instructions result in type error HOT 1
- Not initializing when user is using adblocks HOT 1
- window.intercom("update") not working
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-intercom.