From 8c329dcf2a6bf44a64ce06bffb7827846f1b09c9 Mon Sep 17 00:00:00 2001 From: Matthew Peveler Date: Mon, 18 May 2020 07:16:00 +0300 Subject: [PATCH] disable asset hash for woff and woff2 files out of the box (#1231) Signed-off-by: Matthew Peveler --- config.rb | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/config.rb b/config.rb index 22e956dd8df..6f8b677f617 100644 --- a/config.rb +++ b/config.rb @@ -41,13 +41,16 @@ # Build Configuration configure :build do - activate :asset_hash + # We do want to hash woff and woff2 as there's a bug where woff2 will use + # woff asset hash which breaks things. Trying to use a combination of ignore and + # rewrite_ignore does not work as it conflicts weirdly with relative_assets. Disabling + # the .woff2 extension only does not work as .woff will still activate it so have to + # have both. See https://github.com/slatedocs/slate/issues/1171 for more details. + activate :asset_hash, :exts => app.config[:asset_extensions] - %w[.woff .woff2] # If you're having trouble with Middleman hanging, commenting # out the following two lines has been known to help activate :minify_css activate :minify_javascript - # activate :relative_assets - # activate :asset_hash # activate :gzip end