Skip to content

Commit f871557

Browse files
committed
docs: highlight lit templates
1 parent cb9556d commit f871557

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

eleventy.config.cjs

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,17 @@ module.exports = function(eleventyConfig) {
5050
});
5151

5252
/** fancy syntax highlighting with diff support */
53-
eleventyConfig.addPlugin(SyntaxHighlightPlugin);
53+
eleventyConfig.addPlugin(SyntaxHighlightPlugin, {
54+
init() {
55+
const register = require('prismjs/components/index');
56+
register([
57+
'html',
58+
'regex',
59+
'js-templates',
60+
'javascript',
61+
]);
62+
},
63+
});
5464

5565
/** Strip empty paragraphs */
5666
eleventyConfig.addPlugin(EmptyParagraphPlugin);

0 commit comments

Comments
 (0)