faceyspacey / redux-first-router-link

<Link /> + <NavLink /> that mirror react-router's + a few additional props
MIT License
55 stars 33 forks source link

Can't import Link anymore #138

Open Alevale opened 12 months ago

Alevale commented 12 months ago

I've done an upgrade to my application. Nothing fancy, and I just moved to latest version on this library (2.X.X) along with the rest of my application.

Long story short, After correctly importing the Link component (import Link from 'redux-first-router-link' ) I've come accross this error Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object.

If I try to import it with brackets import { Link } from 'redux-first-router-link'; The error is the following export 'Link' (imported as 'Link') was not found in 'redux-first-router-link' (possible exports: NavLink, __esModule, default) (showing that only NavLink has been exposed with brackets which is expected by reading the documentation)

Temporary solution:

I don't think this is the best solution, but at least it helps till you get the package removed/fixed