-
Notifications
You must be signed in to change notification settings - Fork 0
API
astronomizedev edited this page Sep 4, 2019
·
1 revision
You can use the API to parse lop files right from your node module.
First, install lop for your node module;
npm install lop-language
Next, require lop in your module.
var lop = require('lop-language')
Now, you can parse lop using the following methods;
// Returns parsed html code read from the file.
lop.toHtml('path/to/file.lop')
// Returns parsed html code
lop.toHtmlCode(`
text>
Hello, World!
<<
`)
// Returns parsed markdown code read from the file.
lop.toMarkdown('path/to/file.lop')
// Returns parsed markdown code
lop.toMarkdownCode(`
text>
Hello, World!
<<
`)