I'm trying to generate an input form for numbers (passed via props) and store the user input in the inputValues array. My code is as follows:
export default defineComponent({ name: 'name', props: [ 'number', ], data() { return { inputValues: [] } } });
But nothing is stored in inputValues. What did i do wrong? Also, how do I give the input field a different id so that I can style it differently in CSS later?
Edit: I managed to get it working!
;
I managed to make it work. v-bind: or ":" should not be used with v-model. I added the index because n starts at 1 instead of 0.