-2
Well, guys, what I’d like to know is, is there any way to set the default values for the vuetify components' props? So I don’t have to repeat the props every time I use the component in the style I want.
As in the following example where I have to put 5 props to have the style I want:
new Vue({
el: '#app',
vuetify: new Vuetify(),
})
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/vuetify.min.css" rel="stylesheet">
<div id="app">
<v-app>
<v-text-field
placeholder="Nome"
outlined
flat
dense
solo
required
></v-text-field>
</v-app>
</div>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/vue.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/vuetify.js"></script>
Thanks but I have a question: Why it is better to use single file instead of Vue.Component?
– Igor De Moraes Sampaio
I don’t know much about Vue.Component, but I can’t tell if it’s possible to load with Vue.component. I also think that to see the code itself and give maintenance later becomes simpler with SFC. But really, for this particular case you went through, I think it doesn’t matter much whether it’s SFC or Vue.Component.
– guastallaigor