Skip to content

Commit

Permalink
Add hook for custom javascript
Browse files Browse the repository at this point in the history
  • Loading branch information
erikhofer committed May 23, 2019
1 parent b276281 commit a4fb6fd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ code-freak.ide.idle-check-rate=60000
# Time span after which an idle container is shut down. Default 10 minutes.
code-freak.ide.idle-shutdown-threshold=600000

# This can be used to inject custom javascript code (needs to include script tags).
# It is injected after dependencies (like jQuery) and before template specific scripts.
code-freak.frontend.custom-script=

# Hides HHH000424: Disabling contextual LOB creation as createClob() method threw error
logging.level.org.hibernate.engine.jdbc.env.internal.LobCreatorBuilderImpl = WARN

Expand Down
1 change: 1 addition & 0 deletions src/main/resources/templates/layout/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@
</div>

<script src="/assets/script.js"></script>
<div th:remove="tag" th:utext="${@environment.getProperty('code-freak.frontend.custom-script')}"></div>
<div layout:fragment="scripts" th:remove="tag"></div>
</body>
</html>

0 comments on commit a4fb6fd

Please sign in to comment.