admin管理员组文章数量:1123011
I'm trying to use Bootstrap (v5.3) Badges.
When I use the example of docs:
<button type="button" class="btn btn-primary position-relative">
Inbox
<span class="position-absolute top-0 start-100 translate-middle badge rounded-pill bg-danger">
99
</span>
</button>
it works perfectly. But, if I replace the 99 with a thymeleaf portion, that didn't work.
<button type="button" class="btn btn-primary position-relative">
Inbox
<span class="position-absolute top-0 start-100 translate-middle badge rounded-pill bg-danger">
${numberDependents}
</span>
</button>
I've tried many ways:
${numberDependents}
__${numberDependents}__
[[${numberDependents}]]
<span th:text="${numberDependents}"></span>
<span th:text="|${numberDependents}|"></span>
<span th:text="__${numberDependents}__"></span>
<span th:text="[[${numberDependents}]]"></span>
And no one worked... any suggestions?
本文标签: Thymeleaf don180t work with bootstrap badgesStack Overflow
版权声明:本文标题:Thymeleaf don´t work with bootstrap badges? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736539661a1944370.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论