Skip to content

The core module, DruxtClient, DruxtStore and the DruxtModule base component.

Druxt (druxt)

View source on GitHub

Druxt

Renders the specified Druxt module component, with support for wrapper and inner elements.

Example

<Druxt
  :module="module"
  :props-data="propsData"
  :wrapper="{
    component,
    propsData: {}
  }"
/>

.setModuleComponent()

Sets the module component and propsData.

Kind: instance method of Druxt


.props

Vue.js Props.

Kind: static property of Druxt


.inner : object

Inner element.

Kind: static property of props
Default: { component: 'div', propsData: {} }


.module : string

The DruxtJS module to render.

Kind: static property of props
Example (Using the DruxtJS Site module.)

<Druxt module="site" />

.propsData : object

Props data to bind to the specified DruxtJS module.

Kind: static property of props
Example (Using the DruxtJS Entity module to render a 'node--article' resource.)

<Druxt
  module="entity"
  :props-data="{
    mode: 'teaser',
    type: 'node--article',
    uuid
  }"
/>

.value : Array | Boolean | Date | Number | Object | String

The module value.

Kind: static property of props
Model:


.wrapper : object

Wrapper element.

Kind: static property of props
Default: { component: 'div', propsData: {} }


.v-model : (Array | Boolean | Date | Number | Object | String)

The module value.

Kind: static property of props
Default:


.data(vm)

Vue.js Data object.

Kind: static method of Druxt

ParamTypeDescription
vmobjectThe component ViewModel.
vm.value*The module component model value.

Properties

NameTypeDescription
componentobjectThe module component and its propsData.
model*The module component model value.