Vue Data Bind

Posted on  by admin
Modified5 years, 10 months ago.

I am trying to bind a sortable list in Vue.js, but the underlying data list is not updated:.

135135 bronze badges. 24.9k2020 gold badges9696 silver badges119119 bronze badges. 9696 silver badges119119 bronze badges.

Working Vue.js Sortable jsFiddle:

11 gold badge1818 silver badges4545 bronze badges. 4545 bronze badges. In Vue, v-bind lets you bindan HTML attribute to a JavaScript expression. There are two broad use cases forthis one-way data binding:.

Binding to built-in attributes, like href or class.

You can use v-bind to bind built-in HTML attributes to JavaScript expressions.For example, you can make a link whose href is bound to a data field.

Whenthe link field changes, so does the href. You can use this syntax for some cool use cases, including dynamic inline style attributes.

You can also use v-bind to pass props to child components.

The v-bind part of v-bind:prop is optional. You can also use :prop.Most large Vue codebases use :prop and avoid typing out v-bind. Vue School has some of our favorite Vue video courses. Their Vue.js Master Class walks you through building a real world application, and does a great job of teaching you how to integrate Vue with Firebase.

Modified3 years, 4 months ago.
Pascal LamersPascal Lamers