From cf9bc8d45f274941bf5c8b4183fa38b8fe436604 Mon Sep 17 00:00:00 2001 From: Daniel Micay Date: Mon, 17 May 2021 10:02:00 -0400 Subject: use SVG for /favicon.ico if browser asks for it This makes Chromium use the SVG favicon universally including as the favicon for non-HTML files. --- nginx/nginx.conf | 3 +++ 1 file changed, 3 insertions(+) (limited to 'nginx') diff --git a/nginx/nginx.conf b/nginx/nginx.conf index 3f87f22e..6a6dbb1c 100644 --- a/nginx/nginx.conf +++ b/nginx/nginx.conf @@ -215,6 +215,9 @@ http { } location = /favicon.ico { + if ($http_accept ~ "image/svg\+xml") { + rewrite ^ /favicon.svg last; + } include snippets/security-headers.conf; # avoid breaking image hotlinking such as https://github.com/TryGhost/Ghost/issues/12880 add_header Cross-Origin-Resource-Policy "cross-origin" always; -- cgit v1.3.1