Skip to content

Unexpected v-model error #240

Closed
@KristofMorva

Description

@KristofMorva

The valid-v-model throws an 'v-model' directives cannot update the iteration variable 'x' itself error, even if the iteration variable is not modified (3.14.0).

For example, the following case works perfectly:

v-for="i in 4" v-model="numbers[i]"

However, if we introduce a BinaryExpression, the error above will be produced:

v-for="i in 4" v-model="numbers[i - 1]"

I might be wrong, but I believe this construction should be allowed, as

  • it works
  • the error message does not fit the scenario (iteration variable is not modified)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions