Vue.js: Up and Running by Callum Macrae

Vue.js: Up and Running by Callum Macrae

Author:Callum Macrae
Language: eng
Format: epub, mobi, pdf
Publisher: O'Reilly Media, Inc.
Published: 2018-02-22T16:00:00+00:00


The Data Object

The data object is where you specify attributes that will affect the component or element. If you were writing a template, that’s everything that goes between the tag name and the closing >. For example, with <custom-button type="submit" v-bind:text="buttonText">, the attributes would be type="submit" v-bind:text="buttonText".

In this example, type is a normal HTML attribute being passed through to the component, and text is a component prop bound to the buttonText variable. For the same example using createElement, you could write the following:



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.