Simplify the warnings (PROD_WARNING->WARNING, DEV_WARNING->ERROR). #1051
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.
Instead of distinguishing PROD_WARNING, DEV_WARNING and interpreting
those as WARNING or ERROR depending on the mode in which the
validator runs (this Javascript implementation was always in dev mode),
just make it ERROR or WARNING in the first place. This puts to rest
the complicated scheme which I introduced a while ago,
#174 (comment),
which for the most part treated the development tag on the top-level
html attribute. But since #development=1 has been introduced, suppressing
this error is less important.
Practical changes:
The development attribute: Now always ERROR, even here in Javascript.
So, putting this attribute will make validation fail, but the error
is descriptive and also, the #development=1 alternative is
available.
A11Y errors: These are errors, but they're only implemented in Javascript
thus far and were already errors.
Deprecation: These are warnings, both in Javascript and C++. What changes
is the Javascript, these used to be marked as errors in DEV mode; now
they're warnings, just like in production. I think this is more
straight-forward.