You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
LiteWebJarsResourceResolver does not resolve directories #36726
That's an issue for us, because the browser requests unversioned files due to the unversioned directory, which get cached due to the cache control header.
This appears to be a limitation in LiteWebJarsResourceResolver where only file resources are resolved to versioned paths, while directory paths are not.
From the current flow:
Directory paths (e.g. /webjars/.../lang/) are passed down to PathResourceResolver
Since directories are not considered "readable" resources, resolution returns null
As a result, the original (unversioned) path is preserved
This leads to inconsistent behavior:
File paths → correctly versioned
Directory paths → remain unversioned
In our case, this causes issues with caching because browsers cache unversioned directory-based requests, which can result in stale assets after upgrades.
It would be helpful if the resolver could:
Either resolve directory paths to their versioned equivalents, or
Provide a documented way to obtain versioned base paths for WebJars
Happy to help explore a fix if this behavior is considered unintended.
Activity
AtharvUrunkar commentedon Apr 29, 2026
This appears to be a limitation in LiteWebJarsResourceResolver where only file resources are resolved to versioned paths, while directory paths are not.
From the current flow:
/webjars/.../lang/) are passed down to PathResourceResolverThis leads to inconsistent behavior:
In our case, this causes issues with caching because browsers cache unversioned directory-based requests, which can result in stale assets after upgrades.
It would be helpful if the resolver could:
Happy to help explore a fix if this behavior is considered unintended.
Resolve URL path for versioned webjar directories
Resolve URL path for versioned webjar directories