Commit Graph

2 Commits (24f8b36afff519514686afa01fb8fc080f4ff6f0)

Author SHA1 Message Date
Peter Cai 311b9a0d26
hljs: binding: catch hljs errors when specifying language
the language may not exist. do not crash the entire program due to this
2020-04-12 17:01:45 +08:00
Peter Cai f519152465
integrate hljs into backend to provide code highlighting
1. Use hljs and wasm_bindgen to parse code
2. Allow the final user to choose what language to include by generating
   inline_js in build.rs for #[wasm_bindgen] (a thin wrapper around the
   raw hljs to load whatever is needed by config.json statically rather
   than dynamically)
3. Integrate the monokai color scheme into our default theme
2020-04-12 16:53:51 +08:00