We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
No response
[email protected]
20
15
Use SVGR with webpack as described here https://blog.logrocket.com/import-svgs-next-js-apps/#import-svgs-next-js-using-svgr
Running dev or build fails
`./node_modules/.pnpm/@payloadcms[email protected][email protected]_next@15.0.0-rc.0_@babel[email protected]_react-d_6btuzme2v3pjqg2bytl3nrltfa/node_modules/@payloadcms/ui/dist/assets/payload-favicon.svg Module parse failed: Unexpected token (1:0) You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| <style> | path {
Import trace for requested module: ./node_modules/.pnpm/@payloadcms[email protected][email protected]_next@15.0.0-rc.0_@babel[email protected]_react-d_6btuzme2v3pjqg2bytl3nrltfa/node_modules/@payloadcms/ui/dist/assets/payload-favicon.svg`
"@svgr/webpack": "^8.1.0"
The text was updated successfully, but these errors were encountered:
Add this whole thing to your next.config.js, this is what resolved it for me.
https://react-svgr.com/docs/next/#usage
Sorry, something went wrong.
Hey @pcarillion can you confirm if the above fixes this issue for you please? I'll close the issue for now unless there's further problems confirmed
No branches or pull requests
Link to reproduction
No response
Payload Version
[email protected]
Node Version
20
Next.js Version
15
Describe the Bug
Use SVGR with webpack as described here
https://blog.logrocket.com/import-svgs-next-js-apps/#import-svgs-next-js-using-svgr
Running dev or build fails
`./node_modules/.pnpm/@payloadcms[email protected][email protected]_next@15.0.0-rc.0_@babel[email protected]_react-d_6btuzme2v3pjqg2bytl3nrltfa/node_modules/@payloadcms/ui/dist/assets/payload-favicon.svg
Module parse failed: Unexpected token (1:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| <style>
| path {
Import trace for requested module:
./node_modules/.pnpm/@payloadcms[email protected][email protected]_next@15.0.0-rc.0_@babel[email protected]_react-d_6btuzme2v3pjqg2bytl3nrltfa/node_modules/@payloadcms/ui/dist/assets/payload-favicon.svg`
Reproduction Steps
Adapters and Plugins
"@svgr/webpack": "^8.1.0"
The text was updated successfully, but these errors were encountered: