asciidoctor-caniuse
v0.1.1
Published
Asciidoctor extension to request the caniuse API
Downloads
4
Maintainers
Readme
:earth_africa: "Can I Use" Extension for Asciidoctor.js
An extension for Asciidoctor.js to render browser support tables for modern web technologies.
Install
$ npm i asciidoctor.js asciidoctor-caniuse
Usage
In your document, use the caniuse
macro with the name of the feature:
.battery status
caniuse:battery-status[]
Register the extension before converting your document:
const asciidoctor = require('asciidoctor.js')()
const caniuseExtension = require('asciidoctor-caniuse.js')
const registry = caniuseExtension.register(asciidoctor.Extensions.create())
asciidoctor.convertFile('sample.adoc', { extension_registry: registry })
Rendering
NOTE: You can use a docinfo
file to add custom stylesheet. See the examples
directory.