user101289
user101289

Reputation: 10422

Binding dynamic form values with vue.js

I've built a dynamic set of form inputs using vue.js, where the form inputs are generated from an external list of inputs.

My problem is that I don't see how I can bind the input values back to the vue model, so that the vue instance can access / interact with the form values.

I've created a basic fiddle to give you the idea here: https://jsfiddle.net/gzprj5ef/

Is it possible to update the vue instance with the form values?

Upvotes: 3

Views: 3302

Answers (2)

Yerko Palma
Yerko Palma

Reputation: 12339

You have to remove double brackets when you are using v-model.

Here is the updated jsfiddle

Upvotes: 3

lega
lega

Reputation: 76

You can use v-model="input.value", and you can take a result in variable 'inputs'.

Upvotes: 1

Related Questions