mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Make theme able to load custom javascript (#1211)
* Make theme able to load custom javascript - Look for the field 'customScript' in editorTheme (settings.js) - Add it to mustach context - Load list on template side (index.mst) * Add unit tests for customScripts * Code review edits : generic behavior for theme.page.[css|scripts] - Use the same way to share css and javascript files from a theme - Allow string instead of array for theme.page.scripts - Remove old customScript field
This commit is contained in:
@@ -199,6 +199,9 @@
|
||||
<script src="vendor/ace/ext-language_tools.js"></script>
|
||||
<script src="{{ asset.red }}"></script>
|
||||
<script src="{{ asset.main }}"></script>
|
||||
{{# page.scripts }}
|
||||
<script src="{{.}}"></script>
|
||||
{{/ page.scripts }}
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
Reference in New Issue
Block a user