Using markdown to document the nodes while adhering to node-red style guide #60
Closed
Steve-Mcl
started this conversation in
Design Proposals
Replies: 3 comments 3 replies
|
Like it 😊 Will it be possible to break into html as well if needed? |
2 replies
|
@knolleary what are you thoughts on this making its way into 2.1? Is there time? Regarding the question about enabling/disabling/globally applied to markdown, I think the syntax is sufficiently specific (see example below) as to not be stumbled upon by accident. Also, as we would want this to work in the node description markdown, there are not may other places this would cause a problem example... |
1 reply
PR Here |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Request
As raised by mannharleen in the forum...
Additional info
Node documentation already supports markdown documentation via a script tag with
typeattribute set to"text/markdown"......however, there is currently no means of styling the markdown to node-red documentation style guildlines.
Proposed Solution
markedextensions to convert markup from markdown text to generate HTML that adheres to the Node help style guideProposed markup
Result before custom extensions...
Result after custom extensions...
Issues / Hurdles
markedadds a<p>to ordered lists. This causes the text after a number in the numbered list to be on a new line. To fix this, a new style rule is required...enableExtensionsin the custom extensions callbacks and return tokens/renderings based on its state.Working demo
http://jsfiddle.net/4uwfeb6n/6/
Additional
Tables are currently rendered with very little style making them hard to read. This proposal would also like to include CSS for node-help tables...
Markdown (standard table syntax)...
Current rendering of table in node-red help side-bar...

With proposed CSS...

All reactions