posthtml-hint

0.8.3 • Public • Published

NPM Deps Coverage Standard Code Style Chat

Hint Plugin

Install

npm i -D posthtml-hint

Usage

Options

Rules [String|Object]

Rules Reference

const hint = require('posthtml-hint')('./path/to/.htmlhintrc')

Example

const { readFileSync } = require('fs')
 
const posthtml = require('posthtml')
 
const hint = require('posthtml-hint')(/* options */)
const html = readFileSync('./index.html', 'utf8')
 
posthtml([ hint ])
  .process(html)
  .then(result => console.log(result.html))

Console

PostHTML HINT
-------------
 
✖ error [10:12]
Special characters must be escaped : [ > ].
 
✖ error [12:3]
Special characters must be escaped : [ < ].
 
✖ error [12:21]
Special characters must be escaped : [ < ].
 
✖ error [12:30]
Special characters must be escaped : [ > ].
 
✖ error [15:17]
Tag must be paired, no start tag: [ </h1> ]
 
⚠  5 Errors

Maintainers


Michael Ciniawsky

Contributing

See PostHTML Guidelines and contribution guide.

LICENSE

MIT

/posthtml-hint/

    Package Sidebar

    Install

    npm i posthtml-hint

    Weekly Downloads

    4

    Version

    0.8.3

    License

    MIT

    Unpacked Size

    7.92 kB

    Total Files

    11

    Last publish

    Collaborators

    • cossssmin
    • scrum
    • voischev
    • michael-ciniawsky