From cb5bf1058306bad5064128b886855df58cbf5f39 Mon Sep 17 00:00:00 2001 From: Jonas Braathen Date: Tue, 26 Mar 2019 22:30:20 +0100 Subject: [PATCH] Whitelist some CSS --- gatsby-config.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/gatsby-config.js b/gatsby-config.js index 6ccf83c..f359fbf 100644 --- a/gatsby-config.js +++ b/gatsby-config.js @@ -45,7 +45,13 @@ module.exports = { }, 'gatsby-plugin-sharp', 'gatsby-transformer-sharp', - 'gatsby-plugin-purgecss', + { + resolve: 'gatsby-plugin-purgecss', + options: { + printRejected: true, + whitelistPatterns: [/^(.*)-content(.*)/, /^event-grouped-by-(.*)/], + }, + }, 'gatsby-plugin-netlify', // make sure to keep it last in the array ], }