Skip to content

Latest commit

 

History

History
40 lines (29 loc) · 979 Bytes

readme.md

File metadata and controls

40 lines (29 loc) · 979 Bytes

RedLight

Simple syntax highlighted html generator for Red.
Highlighting is done by css, and sample css files in the 'css' folder.

Example

example image

Usage

The code below introduces to-html function.

do %red-light.red

to-html generates string of pre and code tag data include the argument code.

to-html {test: 1
print test
; console shows 1}

without /header refinement, you need to set css reference on the html manually.

Also source file and url can be used.

to-html %check-folder-or-file.red
to-html https://raw.githubusercontent.com/koba-yu/RedStudy/master/Samples/check-folder-or-file.red

With /header refinement, the html would contain header tag and css reference that was specified by css word.
(Currently it expects the css file exists on the same folder of the html.)

to-html/header {test: 1
print test
; console shows 1} 'monokai_extended ; css name to be used.