html-validate
Advanced tools
Changelog
0.24.2 (2019-03-31)
meta-refresh
.element:ready
triggered after an element and its children has been
fully constructed.init()
and setup()
.require-sri
.<slot>
element.Changelog
0.24.1 (2019-03-26)
Changelog
0.24.0 (2019-03-26)
wcag/h36
.wcag/h30
.long-title
.empty-title
.UserError
exception which is to be used for any error which is not
caused by an internal error, e.g. configuration errors or a plugin. The error
suppresses the notice about internal error which should be reported as a bug.Changelog
0.23.0 (2019-03-20)
empty-heading
validating headers have textual content.processElement
hook on Source
.textContent
property on DOMNode
to get text (recursive) from child
nodes. A new node type TextNode
is added.firstChild
and lastChild
to DOMNode
.Config
, ConfigData
and ConfigLoader
in shim.Changelog
0.22.1 (2019-02-25)
.children
has been split and moved from HtmlElement
to
DOMNode
. .childNodes
replaces the original .children
but is now typed
DOMNode[]
(and in a future release may contain other node types). A getter
.nodeElements
can be used to access only HtmlElement
from .childNodes
and is typed HtmlElement[]
. If your rules use .children
the<rootDir>
is now respected when configuring plugins.wcag/h37
rule.Changelog
0.22.0 (2019-02-24)
HtmlElement
direct access to attr
is replaced with attributes
. The
former was an key-value object and the latter is a flattened array of
Attribute
.Source
and AttributeData
in shim.HtmlElement
will now store duplicated (or aliased) attributes. The biggest
change this introduces is that classList
will now contain a merged list of
all classes. This is needed when combining a static class
attribute with a
dynamic one.Attribute
got two flags isStatic
and isDynamic
to easily tell if the
value is static or dynamic.processAttribute
hook to yield multiple attributes, typically used
when adding aliased attributes such as :class
. By adding both the alias and
the original the latter can be validated as well (e.g. no-dup-attr
can
trigger for multiple uses of :class
). (fixes #36)HtmlValidate.validateString
, makes it easier
to write tests which requires hooks, e.g. processing attributes.[attr]
selector now matches boolean attributes.attribute-boolean-style
and no-dup-attr
now handles when dynamic
attributes is used to alias other attributes, e.g :required="foo"
no longer
triggers an boolean style and class=".."
combined with :class=".."
no
longer triggers duplicate attributes. (fixes #35)attribute-allowed-values
now ignores boolean attributes with dynamic
values. (partially fixes #35)Changelog
0.21.0 (2019-02-17)
button-type
is replaced with element-required-attributes
.element-required-attributes
replaces button-type
and allows any
element to contain requiredAttributes
metadata.--dump-events
output reduced by hiding element metadata and compacting
location data.<area shape="default">
(fixes #31)Changelog
0.20.1 (2019-02-06)
wcag/h37
and wcag/h67
checks if node exists before testing
tagname.attribute-allowed-values
.Changelog
0.20.0 (2019-01-29)
codeframe
formatter to show not just start location but also end.Changelog
0.19.0 (2019-01-27)
img-req-alt
has been renamed wcag/h37
.prefer-button
.Attribute
now stores location of value.wcag/h32
and wcag/h67
.location
and isRootElement
to DOMNode
and add new nodeType
property.Attribute.valueMatches
to test attribute value. Handles DynamicValue
.querySelector
now handles selector lists (comma-separated selectors)