how to pass thymeleaf variable to javascript code example
Example: use thymeleaf variable in javascript
<script th:inline="javascript"> // Enable Thymeleaf inlining
var email = [[${user.email}]]; // Behaves just like in HTML
</script>
<script th:inline="javascript"> // Enable Thymeleaf inlining
var email = [[${user.email}]]; // Behaves just like in HTML
</script>