From 54ebba37c45d6e01d4d58fdcd89b886f6425fe4a Mon Sep 17 00:00:00 2001 From: David Svantesson Date: Mon, 20 Jan 2020 07:08:21 +0100 Subject: [PATCH] Add instructions to README --- README.md | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4df70f1..62de4a3 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,32 @@ # plantuml-code-highlight -Javascript necessary to render plantuml from content in a html-block of class "language-plantuml". Possible to use with Gitea. \ No newline at end of file +Javascript necessary to render plantuml from content in a html-block of class "language-plantuml". Possible to use with Gitea. + +## Install +Copy the javascript files to your server. Then to convert all html blocks having the class `language-plantuml` add the following to the html page: +```html + + + + +``` + +Specifically for Gitea: Copy the javascript files to your `custom/public` folder. Then place the following code in `custom/footer.tmpl`: +```html +{{if .RequireHighlightJS}} + + + + +{{end}} +``` + +## License +deflate.js: Copyright (C) 1999 Masanao Izumo . Some sources claim this to be GPL-2 +encode.js: From https://plantuml.com/code-javascript-synchronous. GPL-3 +plantuml_codeblock_parse.js: David Svantesson. MIT or GPL-2 or GPL-3 at your choice. +