When importing the package using the documented syntax:
import Marquee from "react-fast-marquee";
React throws:
Element type is invalid: expected a string (for built-in components) or a class/function but got: object.
Logging the import shows:
{
default: {
$$typeof: Symbol(react.forward_ref),
render: ƒ
},
__esModule: true
}
The component works when using:
import MarqueeModule from "react-fast-marquee";
const Marquee = MarqueeModule.default;
but the documented default import does not work.
When importing the package using the documented syntax:
import Marquee from "react-fast-marquee";
React throws:
Element type is invalid: expected a string (for built-in components) or a class/function but got: object.
Logging the import shows:
{
default: {
$$typeof: Symbol(react.forward_ref),
render: ƒ
},
__esModule: true
}
The component works when using:
import MarqueeModule from "react-fast-marquee";
const Marquee = MarqueeModule.default;
but the documented default import does not work.