A simple JS Worker module for use with Omnis Studio.
Allows you to convert Markdown text into HTML.
Built around the excellent marked package.
Run the following in Omnis Studio's jsworker folder:
npm install omnis-markdown
Then add an entry for this to your omnis_modules.js file:
const moduleMap = {
markdown: require('omnis-markdown'),
...
};
Converts the passed markdown text into HTML.
Input Parameter must be a Row with a column named markdown.
Do lParams.$define()
Do lParams.$cols.$add("markdown",kCharacter,kSimplechar)
Calculate lParams.markdown as iMarkdownText
Do iJSWorker.$callmethod("markdown","processMarkdown",lParams) Returns #F
Will return the result to $methodreturn's parameter row, in a column named html.