-
Notifications
You must be signed in to change notification settings - Fork 351
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
[nextjs] Throws css imported by dependancy error #32
Comments
Same question! |
Any movement on this? |
I was able to get this working by forking the repo, removing the imported CSS file from ImageEditorWrapper.js, rebuilding and publishing a private version for myself, and then importing the CSS file in
This should work for create-react-app as well, or any webpack configuration that enables file imports. |
How did you build the fork? is |
@odegraciajr, I actually found an even better solution :) Using the webpack configuration below - which is from the bottom of this thread - allows you to use filerobot directly with NextJS. One note, if you use styled-components in your app, you will get warnings about different versions unless you use the version that they are also using.
I also had to use next/dynamic as follows:
|
When i try to use the file upload plugin with next i receive the following error in the dev console
https://github.com/zeit/next.js/blob/master/errors/css-npm.md
It's caused by line https://github.com/scaleflex/filerobot-image-editor/blob/master/projects/react/ImageEditorWrapper.js#L7
What is the most optimal fix for the above??
The text was updated successfully, but these errors were encountered: