Skip to content

Build your personal knowledge base with Trilium Notes

chore(share): introduce theme script

Elian Doran3def1a1e5732
diff --git a/packages/share-theme/src/templates/page.ejs b/packages/share-theme/src/templates/page.ejs
index fcfcf4d237..15ba3efd58 100644
--- a/packages/share-theme/src/templates/page.ejs
+++ b/packages/share-theme/src/templates/page.ejs
@@ -57,6 +57,9 @@ const customServerYml = `- url: "{protocol}://{domain}:{port}/etapi"
<% for (const cssRelation of note.getRelations("shareCss")) { %>
<link href="api/notes/<%= cssRelation.value %>/download" rel="stylesheet">
<% } %>
+ <% if (!note.isLabelTruthy("shareOmitDefaultCss")) { %>
+ <script type="module" src="assets/scripts.js"></script>
+ <% } %>
<% for (const jsRelation of note.getRelations("shareJs")) { %>
<script type="module" src="api/notes/<%= jsRelation.value %>/download"></script>
<% } %>