Skip to content

Latest commit

 

History

History
21 lines (13 loc) · 787 Bytes

code_highlight.md

File metadata and controls

21 lines (13 loc) · 787 Bytes

Code highlightning

Reflex uses Pygments for code highlight and has a lot of styles ready to use. You just need to pick one from here and set it in your pelicanconf.py.

Example:

PYGMENTS_STYLE = "monokai"

Remember to remove .min.css from the file name.

Most of the styles look like the ones at the Pygments demo.

How to add new Styles?

Except for github all other styles are built-in from Pygments. If you want to add a new one, you need to find a Python package that is what you want or you can create your own.

After this, you can run this tool to generate all Pygments CSS files and run gulp to minify.