1
0
mirror of synced 2025-01-27 04:41:41 +03:00
vue-formulario/src/FormulateInputMixin.js
2019-10-08 23:54:16 -04:00

26 lines
389 B
JavaScript

/**
* Default base for input components.
*/
export default {
props: {
context: {
type: Object,
required: true
}
},
computed: {
type () {
return this.context.type
},
id () {
return this.context.id
},
attributes () {
return this.context.attributes || {}
},
hasValue () {
return !!this.context.model
}
}
}