🐛 Bug Report
I need basically need to keep the svg viewBox when using @svgr/webpack.
I tried every piece of documentation I found spread among web pages and tickets previously opened in git.
svgr/webpack version: 5.1.0
webpack version: 4.29.6
To Reproduce
Configurations I tried:
webpack config file:
{
test: /\.svg$/,
use: [{
loader: '@svgr/webpack',
options: {
svgoConfig: {
plugins: [{
removeViewBox: false
}]
}
}
}, 'file-loader']
},
in .svgorc:
plugins:
- removeViewBox: false
with the webpack config file I tried inside my application:
import svgfileurl , { ReactComponent as svgFile } from 'whatevever.svg'
both svgfileurl and svgFile return a function which returns a reactComponent
Expected behavior
For the viewBox attribute to be preserved
Any ideas?
🐛 Bug Report
I need basically need to keep the svg viewBox when using @svgr/webpack.
I tried every piece of documentation I found spread among web pages and tickets previously opened in git.
svgr/webpack version: 5.1.0
webpack version: 4.29.6
To Reproduce
Configurations I tried:
webpack config file:
in .svgorc:
with the webpack config file I tried inside my application:
import svgfileurl , { ReactComponent as svgFile } from 'whatevever.svg'both svgfileurl and svgFile return a function which returns a reactComponent
Expected behavior
For the viewBox attribute to be preserved
Any ideas?