diff --git a/nginx.conf b/nginx.conf index 6ad948b..7a40318 100644 --- a/nginx.conf +++ b/nginx.conf @@ -9,15 +9,13 @@ server { try_files /index.html =404; } - # Deck paths: /resume/, /resume/1, /demo/assets/style.css, etc. - # For /resume/1: $uri (no file) → $uri/ (no dir) → fallback to /resume/index.html - # For /demo/assets/style.css: $uri (real file) → served directly + # /resume/1, /demo/assets/style.css — paths with trailing slash location ~ ^/([^/]+)/ { try_files $uri $uri/ /$1/index.html =404; } # /resume (no trailing slash) → 301 redirect to /resume/ - location / { + location ~ ^/([^/]+)$ { try_files $uri $uri/ =404; } }