react-aad
react-aad copied to clipboard
Warning: React.createElement: type is invalid -- expected a string
trafficstars
Hi All! Steps to reproduce: When I use:
"dependencies": {
"react-aad-msal": "2.3.5",
"react-microsoft-login": "1.8.5"
}
import { AzureAD } from 'react-aad-msal';
in create react app (dev env) all work fine. But after build(prod env) I got:
Actual result:
Warning: React.createElement: type is invalid -- expected a string (for built-in components)
or a class/function (for composite components) but got: undefined. You likely forgot to
export your component from the file it's defined in. Check the render method of
How to fix:
import AzureAD from 'react-aad-msal';
Maybe it's not a bug. But I didn't find it in the documentation.