VueMaker Trait Adds exception based methods to a class, goes well with [System\Traits\ViewMaker](/docs/api/system/traits/viewmaker).

To add a component call registerVueComponent() in a controller action:


This will automatically load the component's JavaScript definition, component template, and CSS file.

See also:

Protected properties

protected array $vueComponents

A list of registered Vue component classes

Public methods

public void outputVueComponentTemplates()

public void registerVueComponent(String $componentClassName)

Registers a Vue component to be loaded when the action view renders.

  • String $componentClassName

Protected methods

protected void isVueComponentRegistered($componentClassName)
  • $componentClassName

protected void makeVueComponent($className)
  • $className