diff options
Diffstat (limited to 'test/plugins/replace_highlight')
-rw-r--r-- | test/plugins/replace_highlight/index.js | 11 | ||||
-rw-r--r-- | test/plugins/replace_highlight/package.json | 9 |
2 files changed, 20 insertions, 0 deletions
diff --git a/test/plugins/replace_highlight/index.js b/test/plugins/replace_highlight/index.js new file mode 100644 index 0000000..25f9642 --- /dev/null +++ b/test/plugins/replace_highlight/index.js @@ -0,0 +1,11 @@ +module.exports = { + blocks: { + "code": { + process: function(blk) { + var lang = blk.kwargs.language || 'code'; + + return lang+"_"+blk.body+"_"+lang; + } + } + } +};
\ No newline at end of file diff --git a/test/plugins/replace_highlight/package.json b/test/plugins/replace_highlight/package.json new file mode 100644 index 0000000..72d1033 --- /dev/null +++ b/test/plugins/replace_highlight/package.json @@ -0,0 +1,9 @@ +{ + "name": "gitbook-plugin-replace_highlight", + "description": "Test replacing default code highlighter", + "main": "index.js", + "version": "0.0.1", + "engines": { + "gitbook": "*" + } +}
\ No newline at end of file |