Package Exports
- doctype
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (doctype) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
doctype
Info on HTML / XHTML / MathML / SVG doctypes.
Installation
npm:
npm install doctypeUsage
var doctype = require('doctype')
doctype(5)
// => 'html'
doctype(4.01)
doctype('4.01t')
doctype('4.01 Transitional')
doctype('HTML 4.01 Transitional')
// => 'HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"'
doctype('svg')
// => 'svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"'API
doctype(name)
Get a doctype, where name stripped from white-space, casing,
fractional-part of version, 'HTML' or 'XHTML' prefix, and
suffixes are normalised (Transitional to t).
Returns: string? — When applicable.
doctype.all
{
'HTML 5': 'html',
'HTML 4.01 Strict': 'HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"',
// ...
}Object mapping doctype names to doctype strings. This gives raw
access to the information returned by doctype().
Related
html-tag-names— List of HTML tag-nameshtml-element-attributes— Map of HTML attributeshtml-void-elements— List of void HTML tag-namesproperty-information— Information on HTML propertiesweb-namespaces— Map of web namespaces