diff --git a/scripts/build.mjs b/scripts/build.mjs index e6261b9..ddc08c9 100644 --- a/scripts/build.mjs +++ b/scripts/build.mjs @@ -30,6 +30,7 @@ const targets = ( }, {}); const chapters = process.argv[4]; +const noCache = process.argv[5] == '--no-cache'; console.log(`Building langs: ${langsToBuild.join(', ')}…`); langsToBuild.forEach((lang) => { @@ -51,7 +52,9 @@ langsToBuild.forEach((lang) => { plugins.ast.h5Counter, plugins.ast.aImg, plugins.ast.imgSrcResolve, - plugins.ast.mermaid, + plugins.ast.highlighter({ + languages: ['javascript', 'typescript'] + }), plugins.ast.ref, plugins.ast.ghTableFix, plugins.ast.stat @@ -70,7 +73,8 @@ langsToBuild.forEach((lang) => { postProcess: [plugins.html.imgDataUri] } }, - chapters + chapters, + noCache }).then((builder) => { Object.keys(targets).forEach((target) => { if (target !== 'landing') { diff --git a/src/css/style.css b/src/css/style.css index 7654c84..1c98cc0 100644 --- a/src/css/style.css +++ b/src/css/style.css @@ -245,3 +245,16 @@ a.anchor { color: inherit; text-decoration: none; } + +.hljs-keyword, +.hljs-variable { + font-weight: bold; +} + +.hljs-string { + color: #2a9292; +} + +.hljs-comment { + color: #655f6d; +}