Thymeleaf:
市面上主流的 Java 模板引擎有:JSP、Velocity、Freemarker、Thymeleaf
JSP本质也是模板引擎,Spring Boot 官方推荐使用 “Thymeleaf”模板引擎
Thymeleaf 官网:https://www.thymeleaf.org/
Thymeleaf 在Github 的主页:https://github.com/thymeleaf/thymeleaf
Thymeleaf 参考手册:https://blog.csdn.net/zrk1000/article/details/72667478/
<a th:href="@{/admin/examination/paper/initAdd}"></a>
th:href@{} : 链接
<a th:href="@{/web/uc/order/orderInfo?orderId={orderId}(orderId=${order['id']})}" class="c-999">详情</a>
th:href@{}:带参数
<script type="text/javascript" th:src="@{
{path}/admin/libs/plugins/layer/laydate/laydate.js?v={v}(path=${staticPath},v=${v})}">
</script>
<script type="text/javascript" th:src="@{/course/cou/select-common-course.js?v={v}(v=${v})}">
</script>
th:src@{} :引入js、css图片等等
<script th:inline="javascript"> </script>
th:inline=“javascript” :页面写js使用 (脚本内联)
th:inline=“text” : (文本内联)