Closed artur-laptev closed 5 years ago
The default css style has a height and width of 16px.
import 'vue-svgicon/dist/svgicon.css'
ref: https://github.com/MMF-FE/vue-svgicon/tree/dev#register-vue-svgicon-plugin
You can set default width and height use plugin options
Vue.use(VueSvgIcon, {
tagName: 'icon',
defaultWidth: '1em',
defaultHeight: '1em'
})
ref: https://github.com/MMF-FE/vue-svgicon/tree/dev#defaultwidth--defaultheight
i know this things, but i have in every svg width and height as attribute, so it's bad if i will set width and height in every vue component
Use scale
prop can help?
<icon scale="1" />
yeap, it works! Thanks ))
Hello, please add the default width and height from svg file. Now it's render without height and width attributes but in svg file i have this attributes