Clarify boolean attribute behaviour is unchanged #31
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The broad wording in a few places fails to draw attention to the fact that
:[booleanAttr]="false"
will be removed from markup, as in Vue 2 (further confusing because @vue/compat incorrectly warned about this issue for boolean attributes until a recent fix). I added a few clarifications to make sure it's clear that this is specifically a change to non-boolean attributes.I also removed the
low-level internal API change
label, because I think it is untrue that this won't affect most developers. HTML attributes changing from not being present to being present with a value of"false"
, could easily have consequences, especially somewhat invisibly for screen-readers, for attributes likearia-label
,aria-labelledby
,id
, etcFor instance: with a binding like
<label for="input">Email</label><input id="input" :aria-label="needsCustomAriaLabel && makeAriaLabel(input)">
the label of the input for a screenreader will change from "Email" to "false" between vue 2 and 3)