Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Module not found: Error: Can't resolve 'loadable-components/snap' #40

Closed
kirkchris opened this issue Feb 6, 2018 · 0 comments
Closed

Comments

@kirkchris
Copy link

kirkchris commented Feb 6, 2018

I'm having an issue loading getState from loadable-components/snap. We're using yarn 1.3.2, node 8.9.3, and loadable-components 1.1.0.

Using import loadable from 'loadable-components'; works just fine in our project, as does attempting to import the loadable-components/server, but if we try to use the snippet for working with snapshots as listed in the Readme:

import { getState } from 'loadable-components/snap'

// Set up for react-snap.
window.snapSaveState = () => getState()

We get the following error:

Module not found: Error: Can't resolve 'loadable-components/snap' in '/app/app'
 @ ./app/index.js 7:0-52
 @ multi (webpack)-dev-server/client?http://0.0.0.0:8080 webpack/hot/dev-server ./app/index.js

Are we importing wrong? Any thoughts?

gregberge added a commit that referenced this issue Feb 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant