===== SyntaxHighlighter-NG =====
Author: [[https://deltalima.org|DeltaLima]]
==== Description ====
Makes [code] blocks syntax highlighted (when language specified) with [[https://prismjs.com|prism.js]]
By default the "small-size" prism.js language support is enabled.
This contains following supported language tags by default:
markup, css, clike, javascript, apacheconf, arduino, atom, bash, basic, batch,
bbcode, c, cpp, cmake, csv, diff, docker, git, go, html, http, ini, java, json,
log, makefile, markdown, markup-templating, nginx, pascal, perl, php,
powershell, python, rss, ruby, shell-session, sql, svg, typescript, vbnet,
visual-basic, wiki, yaml, xml
See [[https://prismjs.com/#supported-languages|prismjs.com#supported-languages]] for the corresponding "[code=]"-tags and the full list of languages which are supported in the full package, you can configure as well.
==== Example ====
** no syntax highlightning **
[code]Just plain text e.g.[/code]
{{:res:plugins:screenshot_2023-06-21_at_11-05-32_deltalima.org_syntaxhighlighter-ng_testpage.png|}}
** PHP code block**
[code=php][/code]
{{:res:plugins:screenshot_2023-06-21_at_11-05-38_deltalima.org_syntaxhighlighter-ng_testpage.png}}
** apache config block**
[code=apacheconf]
Order Deny,Allow
Deny from all
Allow from .foo.com
[/code]
{{:res:plugins:screenshot_2023-06-21_at_11-05-43_deltalima.org_syntaxhighlighter-ng_testpage.png}}
==== Configuration ====
You can configure the prism.js package size to use (tiny, small, full) and the used theme (coy, dark, default, funky, okaidia, solarizedlight, tomorrow, twilight).
Just edit for that config.php
==== Download ====
[[https://git.la10cy.net/attachments/f5e4241b-2dbd-4b3d-9b16-d64b2e2bc691|syntaxhighlighter-ng_v1.0.3.zip]]
or get the [[https://git.la10cy.net/DeltaLima/flatpress-plugin-syntaxhighlighter-ng/|latest main branch from git.la10cy.net]]
For users of the FlatPress-Leggero theme: {{ res:plugins:deltalima:syntaxhighlighter-ng_v1.0.3-fp.zip |}}
==== Demo ====
[[https://deltalima.org/blog/index.php/syntaxhighlighter-ng-testpage/]]
==== Support ====
Please ask for help on the [[https://forum.flatpress.org/viewtopic.php?t=665|FlatPress Forum]]