Skip to content

model is changed to the opposite value if true and false values are reversed #3

@kkyryl

Description

@kkyryl

This is an edge case :)

  • assume value 0 = "running", 1 = "not running" (rather than the usual 1 = running, 0 = not running)
  • isRunning: 0 in data()
  • <toggle v-model="isRunning" :trueValue="0" :falseValue="1"></toggle>
  • expected behavior: isRunning remains 0 until toggled
  • current behavior: when the component is rendered isRunning is immediately updated to 1. Test by removing Toggle component — isRunning remains 0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions