All Projects β†’ ele828 β†’ Hexo Prism Plugin

ele828 / Hexo Prism Plugin

Hexo plugin for code highlighting by prism.js, supporting JSX syntax

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Hexo Prism Plugin

Highlightbracketpair
πŸ”† Highlight bracket pair plugin for intellij
Stars: ✭ 428 (+119.49%)
Mutual labels:  plugin, highlight
Highlightjs Line Numbers.js
Line numbering plugin for Highlight.js
Stars: ✭ 323 (+65.64%)
Mutual labels:  plugin, highlight
prism-pretty
A Chrome Extension to format/highlight/preview HTML/JS/CSS/Markdown code with Prism.js
Stars: ✭ 91 (-53.33%)
Mutual labels:  prism, highlight
Hexo Theme Casper
New casper theme ported to hexo.
Stars: ✭ 132 (-32.31%)
Mutual labels:  hexo, highlight
Multihighlight
Jetbrains IDE plugin: highlight identifiers with custom colors πŸ–ŒπŸ’‘
Stars: ✭ 65 (-66.67%)
Mutual labels:  plugin, highlight
Awesome Hexo
A curated list of awesome things related to Hexo
Stars: ✭ 466 (+138.97%)
Mutual labels:  hexo, plugin
Hexo Generator Search
A plugin to generate search data for Hexo.
Stars: ✭ 318 (+63.08%)
Mutual labels:  hexo, plugin
Hexo Tag Aplayer
Embed aplayer in Hexo posts/pages
Stars: ✭ 552 (+183.08%)
Mutual labels:  hexo, plugin
Vue Prism Component
highlight code using prism.js and vue component
Stars: ✭ 126 (-35.38%)
Mutual labels:  prism, highlight
Hexo Wordcount
A Word Count Plugin for Hexo
Stars: ✭ 150 (-23.08%)
Mutual labels:  hexo, plugin
Aerojump.nvim
Aerojump is a fuzzy-match searcher/jumper for Neovim with the goal of quick keyboard navigation
Stars: ✭ 184 (-5.64%)
Mutual labels:  plugin
Hexo Theme Laughing
A lightweight hexo theme
Stars: ✭ 185 (-5.13%)
Mutual labels:  hexo
Unreal.js Core
Unreal.js plugin submodule
Stars: ✭ 189 (-3.08%)
Mutual labels:  plugin
Bentobox
Expandable Minecraft server plugin for island-type games like SkyBlock or AcidIsland.
Stars: ✭ 192 (-1.54%)
Mutual labels:  plugin
Hexo Theme Butterfly
πŸ¦‹ A Hexo Theme: Butterfly
Stars: ✭ 3,146 (+1513.33%)
Mutual labels:  hexo
Vue Plugin Template
πŸš€ Solid foundation to start a Vue plugin with the best developer experience and a focus on performance
Stars: ✭ 189 (-3.08%)
Mutual labels:  plugin
Sparkliner
Sparkliner β€” easy way to make sparkline graph [Sketch plugin]
Stars: ✭ 184 (-5.64%)
Mutual labels:  plugin
Emoji Search
πŸ˜„ Emoji synonyms to build your own emoji-capable search engine (elasticsearch, solr)
Stars: ✭ 184 (-5.64%)
Mutual labels:  plugin
Post Scheduler
Schedule posts & content updates for static websites (Jekyll, Hugo, Gatsby, Phenomic etc)
Stars: ✭ 184 (-5.64%)
Mutual labels:  hexo
Hexo Theme Miho
πŸΊδΈ€ζ¬Ύε•ζ ε“εΊ”εΌηš„hexo主钘, A single column response for hexo . https://blog.minhow.com
Stars: ✭ 194 (-0.51%)
Mutual labels:  hexo

Hexo-Prism-Plugin NPM

Since highlight.js didn't support JSX syntax properly, I wrote this plugin to replace Hexo's default code highlight plugin.

Install

npm i -S hexo-prism-plugin

Usage

Firstly, you should edit your _config.yml by adding following configuration.

prism_plugin:
  mode: 'preprocess'    # realtime/preprocess
  theme: 'default'
  line_number: false    # default false
  custom_css: 'path/to/your/custom.css'     # optional

After that, check highlight option in _config.yml. Make sure that default code highlight plugin is disabled.

highlight:
  enable: false

Finally, clean and re-generate your project by running following commands:

hexo clean
hexo generate

Options

  • mode:

    • realtime (Parse code on browser in real time)
    • preprocess (Preprocess code in node)
  • theme:

    • default
    • coy
    • dark
    • funky
    • okaidia
    • solarizedlight
    • tomorrow
    • twilight
    • atom-dark
    • base16-ateliersulphurpool.light
    • cb
    • duotone-dark
    • duotone-earth
    • duotone-forest
    • duotone-light
    • duotone-sea
    • duotone-space
    • ghcolors
    • hopscotch
    • pojoaque
    • vs
    • xonokai
  • line_number:

    • true (Show line numbers)
    • false (Default, Hide line numbers)
  • no_assets

    • true (Stop loading asset files)
    • false (Default, load script and stylesheets files)

Themes

You can check out prism-themes project for additional theme preview:

https://github.com/PrismJS/prism-themes#available-themes

Supported languages

You could find the supported languages here:

http://prismjs.com/#languages-list

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].