PostHTML Tape
PostHTML Tape lets you quickly test PostHTML plugins.
-
Install this dependency to your project:
npm install --save-dev posthtml-tape -
Add the
posthtml-tape
task to yourpackage.json
: -
Add tests to your
.tape.js
file:moduleexports ='posthtml-my-plugin':'basic':message: 'supports basic usage';
That’s it! Now you can use the tape
task:
npm run tape
Options
Options may be passed through package.json
using posthtmlConfig
:
Options may be passed through arguments:
posthtml-tape --plugin=path/to/plugin.js --config=path/to/.tape.js