DruxtEntityMixin
DruxtEntityMixin
Provides Vue.js properties to render a DruxtEntity or DruxtEntityForm Wrapper component.
Kind: global mixin
See: /modules/entity
Example
<script>
import { DruxtEntityMixin } from 'druxt-entity'
export default {
mixins: [DruxtEntityMixin],
}
</script>
.props
Kind: static property of DruxtEntityMixin
.entity : object
The Drupal Entity JSON:API resource data.
Kind: static property of props
.fields : object
Drupal Entity Fields data.
Kind: static property of props
.langcode : string
The JSON:API resource language code.
Kind: static property of props
.schema : object
DruxtJS Schema object.
Kind: static property of props
.value : object
The Entity value.
Kind: static property of props
.computed
Kind: static property of DruxtEntityMixin
.classes() : Array.<string>
Array of CSS classes.
Kind: static method of computed
.data(vm)
Provides the reactive entity model, initialized from the value property.
Kind: static method of DruxtEntityMixin
| Param | Type | Description |
|---|---|---|
| vm | object | The component ViewModel. |
| vm.value | object | The Entity value. |
Properties
| Name | Type | Description |
|---|---|---|
| model | object | The model object. |