-
-
Notifications
You must be signed in to change notification settings - Fork 924
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP, don't merge] Fix #1804 and tweak #1595 #1865
Conversation
FYI: #1862 is now merged. |
@pygy Ping...how close to ready is this to merge (another PR might be blocked on this)? |
@vasilrimar reported issues where passing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can only give this a cursory look-through but it seems reasonable to me.
render/render.js
Outdated
if(attrs.value === null) { | ||
if (vnode.dom.selectedIndex !== -1) vnode.dom.value = null | ||
} else { | ||
/*eslint-disable no-implicit-coercion*/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have you tried // eslint-disable-next-line no-implicit-coercion
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. I went for // eslint-disable-line
since it is what we use the most, and normalized the way we use those directives in the code base.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. (I didn't want to abandon this patch.)
before: > mutate styles/properties x 7,999 ops/sec ±10.87% (46 runs sampled) after: > mutate styles/properties x 16,104 ops/sec ±4.36% (66 runs sampled)
Thanks @isiahmeadows the review is most welcome :-) |
This fixes #1804 and tweaks #1595.
removeAttr()
now mirrorssetAttr()
. values set toundefined
ornull
are equivalent to a lack of value, except forselect
, wherenull
There are still possibly problematic corner cases with
select.value
, please don't merge this yet.#1862 can be merged as is in the mean time if you want. I'll rebase this.