.htmlhintrc
HTML Hint configuration file
| Type | object |
|---|---|
| File match |
.htmlhintrc
|
| Schema URL | https://catalog.lintel.tools/schemas/schemastore/htmlhintrc/latest.json |
| Source | https://www.schemastore.org/htmlhint.json |
Validate with Lintel
npx @lintel/lintel check
Properties
Alt of img must be present and alt of area[href] and input[type=image] must be set value.
Attribute name must be lowercase.
The same attribute can't be specified twice.
Attributes should be sorted in an order.
Attribute value cannot use unsafe chars.
Attribute value must be closed by double quotes.
Class attributes should not contain duplicate values. Other attributes can be checked via configuration.
Attribute must set value.
Attribute value must be closed by single quotes.
No leading or trailing spaces inside attribute values.
The type attribute of a button element must be present with a valid value: button, submit, or reset.
Doctype must be first.
Doctype must be HTML5.
A frame or iframe element must have an accessible name.
The method attribute of a form element must be present.
A H1 heading element is required in HTML documents.
The script tag cannot be used in head.
Href must be absolute or relative.
The lang attribute of an element must be present and should be valid.
Id and class cannot use ad keyword, it will be blocked by adblock software.
Id and class value must meet some rules: underline, dash, hump.
ID attributes must be unique in the document.
Inline script cannot be used.
Inline style cannot be used.
A link element with rel="canonical" is required within the
tag.A main element is required within the
tag.A meta charset is required within the
tag.A meta description is required within the
tag.A meta viewport is required within the
tag.Spaces and tabs cannot be mixed in front of line.
Special characters must be escaped.
Src of img(script,link) must set value. Empty of src will visit current page twice.
Style tag cannot be used.
Disallows the use of obsolete HTML tags.
Tag must be paired.
The empty tag must be self-closed.
Tagname must be lowercase.
Tagname must not contain any characters beside letters, numbers, ”-”, ”:” or ”_”.
Check if particular tags are self-closing or must include or exclude particular tags.
title must be present in head tag.