Vuetify 3: Using Svg for v icon
P粉440453689
2023-08-28 21:34:41
<p>I want to use my custom svg as v icon but I didn't find any solution in the Vuetify v3 documentation. </p>
<p>In vuetify v2 I can do something like this in vuetify.js: </p>
<pre class="brush:php;toolbar:false;">export default new Vuetify({
icons:{
values: {
test: {
component: Test,
},</pre>
<p>I can use it like this:</p>
<pre class="brush:php;toolbar:false;"><v-icon size="40">$vuetify.icons.test</v-icon></pre>
<p>How do I do the same thing in Vuetify v3? Thanks for your help :)</p>
The code below shows an example of adding a custom icon to Vuetify along with the mdi icon set and using both icons in a component via aliases.
vuetify.js
folderIcon.vue (your custom icon)
Any Securities Regulatory Commission
Original source: Thread in Vuetify Discord channel