Proof of concept: Automatically determine MUST_USE_PROPERTY/ATTRIBUTE #1512
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.
Hand meet glove #1449 (per node-type list of attributes/properties).
This is a super shitty implementation, but simply to get the discussion going.
Rather than manually determine if something is an attribute or property, this does it automatically. Combined with #1449 this could be done at start-up if preferred (well we could anyway, but then we'd have to keep a minimal set of elements and attributes/properties). Using the same principle we can also determine the type of each property, but it would not work attributes (I think?).
Supported by all browsers? Sure seems so, very quick testing in IE8 revealed no issues.
This naturally feeds into if we should even have these whitelists at all, but it seems like there's a handful of decidedly non-trivial issues/decisions that would have to be resolved/agreed upon. So I intentionally omitted it here to keep it focused, but obviously feel free to discuss it.
2 failed tests, but they are not indicative of a fundamental issue with this patch, simply "changing circumstances" that are coincidentally addressed by my other recent PRs.