This repository reproduces the problem: https://github.com/maio/repro-thymeleaf-slow-urls-problem
When @{...} syntax is used and project contains org.webjars:webjars-locator-lite dependency, it takes much more time to generate resulting HTML.
A lot of time is being spent in ResourceUrlEncodingFilter.ResourceUrlEncodingResponseWrapper#encodeURL.