fix(forms): use expression form for conditional fieldError reset
Vue template attribute expressions don't allow if-statements; the short-circuit form (`x && (x = '')`) is the idiomatic equivalent and runs without a template compiler warning.
This commit is contained in:
parent
e5f1e9f95e
commit
5d4321612f
3 changed files with 4 additions and 4 deletions
|
|
@ -174,7 +174,7 @@
|
|||
placeholder="you@example.com"
|
||||
autofocus
|
||||
@blur="validateNewEmail"
|
||||
@input="if (fieldErrors.email) fieldErrors.email = ''"
|
||||
@input="fieldErrors.email && (fieldErrors.email = '')"
|
||||
@keydown.enter="handleUpdateEmail"
|
||||
@keydown.escape="cancelEmailEdit"
|
||||
>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue