Use webpack entrypoints for bootstrap and bootswatch themes

This allows us to utilize the webpack versioning mechanism, to avoid display issues, when upgrading bootstrap
This commit is contained in:
Jan Böhmer 2023-02-01 22:58:39 +01:00
parent 5c303225d7
commit 489b3e2c21
31 changed files with 541 additions and 71 deletions

View file

@ -41,10 +41,10 @@
{% if theme and theme in constant('App\\Entity\\UserSystem\\User::AVAILABLE_THEMES') %}
<link rel="stylesheet" href="{{ preload(asset('build/themes/' ~ theme ~ '.css'), {as: 'style'}) }}">
{% if theme and theme in constant('App\\Entity\\UserSystem\\User::AVAILABLE_THEMES') and encore_entry_exists('theme_' ~ theme) %}
{{ encore_entry_link_tags('theme_' ~ theme) }}
{% else %}
<link rel="stylesheet" href="{{ preload(asset('build/themes/bootstrap.css'), {as: 'style'}) }}">
{{ encore_entry_link_tags('theme_bootstrap') }}
{% endif %}
{{ encore_entry_link_tags('app') }}