html-styles

Default HTML styles as defined by W3C specification

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
html-styles
251.0.06 years ago6 years agoMinified + gzip package size for html-styles in KB

Readme

Default HTML styles as defined by W3C specification
html-styles
npm install html-styles

Usage

const defaultStyles = require('html-styles');
const applicable = styles.filter(({selectorText}) => document.body.matches(selectorText));

// [
//   { selectorText: "html, body", type: "CSSStyleRule", style: {…}},
//   { selectorText: "address, blockquote, center, div, figure, figcaption, footer, form, header, hr,\nlegend, listing, main, p, plaintext, pre, summary, xmp, article, aside, h1, h2,\nh3, h4, h5, h6, hgroup, nav, section, table, caption, colgroup, col, thead,\ntbody, tfoot, tr, td, th, dir, dd, dl, dt, ol, ul, li, [dir=ltr i],\n[dir=rtl i], [dir=auto i], *|*", type: "CSSStyleRule", style: {…} }
// ]

Scrapeing

yarn install
yarn scrape

License

html-styles is released under the MIT license.