Skip to content

Build your personal knowledge base with Trilium Notes

fix(server): list of syntax highlighting not working properly

Elian Doran5090daed95b7
diff --git a/apps/server/src/services/code_block_theme.ts b/apps/server/src/services/code_block_theme.ts
index 8a3964fcdc..2480d051f3 100644
--- a/apps/server/src/services/code_block_theme.ts
+++ b/apps/server/src/services/code_block_theme.ts
@@ -47,9 +47,11 @@ export function listSyntaxHighlightingThemes() {
export function getStylesDirectory() {
if (isElectron && !isDev) {
return "styles";
+ } else if (!isDev) {
+ return "node_modules/@highlightjs/cdn-assets/styles";
+ } else {
+ return "../node_modules/@highlightjs/cdn-assets/styles";
}
-
- return "node_modules/@highlightjs/cdn-assets/styles";
}
/**