You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Only after I found this comment to add a plugins list to the svgrOptions object and installing @svgr/plugin-svgo it started working.
plugins: ['@svgr/plugin-svgo','@svgr/plugin-jsx']
I assume every thing under svgrOptions should be documented on the following page, but no plugins option is mentioned. Nor is it mentioned that the svgo plugin needs to be explicitly included. I understand this is our of control of this project. (I've also opened gregberge/svgr#919) https://react-svgr.com/docs/options/
The use of SVGO with SVGR and this plugin seems somewhat undocumented.
It seems enabled by default:
https://react-svgr.com/docs/options/#svgo
There is no mention of needing to add a plugin.
Only after I found this comment to add a
plugins
list to thesvgrOptions
object and installing@svgr/plugin-svgo
it started working.I assume every thing under
svgrOptions
should be documented on the following page, but noplugins
option is mentioned. Nor is it mentioned that the svgo plugin needs to be explicitly included. I understand this is our of control of this project. (I've also opened gregberge/svgr#919)https://react-svgr.com/docs/options/
Seeing there are at least 2 issues (#7, #49, #52), open where people are confused maybe add an example to this project's readme?
https://github.com/pd4d10/vite-plugin-svgr
Full example:
The text was updated successfully, but these errors were encountered: