Skip to content

Commit

Permalink
Add Drupal 10+ CSS/JS Aggregation support (#337)
Browse files Browse the repository at this point in the history
  • Loading branch information
joecorall authored Jun 6, 2024
1 parent 86d098d commit 3e2d454
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions drupal/rootfs/etc/nginx/shared/drupal.defaults.conf
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ location ~ ^(/[a-z\-]+)?/system/files/ { # For Drupal >= 7
try_files $uri /index.php?$query_string;
}

# handle CSS/JS aggregation through Drupal
location ~ ^/sites/.*/files/(css|js)/ {
try_files $uri /index.php?$query_string;
}

location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg)$ {
try_files $uri @rewrite;
expires max;
Expand Down

0 comments on commit 3e2d454

Please sign in to comment.