vcl-doc-client
v0.2.2
Published
An HTML viewer for the doc generated by vcl/doc-gen
Downloads
8
Readme
VCL Documentation Client
This is an HTML viewer for the docs based on a JSON structure such as generated by vcl/doc-gen. The doc fragments are included using shadow DOM.
While it has been created for the VCL it is mostly agnostic and can be used to browse any structured documentation.
Demo
Usage
Use vcl/doc-gen to generate the input for
this client.
Or generate the documentation.json
yourself.
Example
// var doc = {...};
var vclDocClient = require('vcl-doc-client');
vclDocClient.getBuild(doc, function(html) {
console.log(html);
});
In order to inject custom CSS or JS before the </body>
tag,
doc.customHTML
can be set accordingly.