v-for

v-for Expects: Array | Object | Number | String Param Attributes: track-by stagger enter-stagger leave-stagger Usage: Render the element or template block multiple times based on the source data. The directive’s value must use the special syntax alias (in|of) expression to provide an alias for the current element being iterated on: <div v-for="item in items"> {{ item.text }} </div> Note using of as the delimiter is only supported in 1.0.17+. Alternatively, you can also specif

Vue.partial()

Vue.partial( id, [partial] ) Arguments: {String} id {String} [partial] Usage: Register or retrieve a global template partial string. // register Vue.partial('my-partial', '<div>Hi</div>') // retrieve registered partial var myPartial = Vue.partial('my-partial') See also: Special Elements - <partial>.

Form Input Bindings

Basics Usage You can use the v-model directive to create two-way data bindings on form input elements. It automatically picks the correct way to update the element based on the input type. Although a bit magical, v-model is essentially syntax sugar for updating data on user input events, plus special care for some edge cases. Text <span>Message is: {{ message }}</span> <br> <input type="text" v-model="message" placeholder="edit me"> Checkbox Single checkbox, boolean v

capitalize

capitalize Example: {{ msg | capitalize }} ‘abc’ => ‘Abc’

array.$set()

array.$set(index, value) Arguments {Number} index {*} value Usage Set an element in the array to a value by index and trigger view updates. vm.animals.$set(0, { name: 'Aardvark' }) See also: Array Detection Caveats

devtools

devtools Type: Boolean Default: true (false in production builds) Usage: // make sure to set this synchronously immediately after loading Vue Vue.config.devtools = true Configure whether to allow vue-devtools inspection. This option’s default value is true in development builds and false in production builds. You can set it to true to enable inspection for production builds.

destroyed

destroyed Type: Function Details: Called after a Vue instance has been destroyed. When this hook is called, all bindings and directives of the Vue instance have been unbound and all child Vue instances have also been destroyed. Note if there is a leaving transition, the destroyed hook is called after the transition has finished. See also: Lifecycle Diagram

vm.$root

vm.$root Type: Vue instance Read only Details: The root Vue instance of the current component tree. If the current instance has no parents this value will be itself.

vm.$once()

vm.$once( event, callback ) Arguments: {String} event {Function} callback Usage: Listen for a custom event, but only once. The listener will be removed once it triggers for the first time.

v-show

v-show Expects: * Usage: Toggle’s the element’s display CSS property based on the truthy-ness of the expression value. Triggers transitions if present. See also: Conditional Rendering - v-show