diff options
-rw-r--r-- | assets/css/dev/postcss.config.js | 30 | ||||
-rw-r--r-- | assets/css/postcss.config.js | 30 | ||||
-rw-r--r-- | assets/css/tailwind.config.js | 10 | ||||
-rw-r--r-- | package.json | 4 |
4 files changed, 39 insertions, 35 deletions
diff --git a/assets/css/dev/postcss.config.js b/assets/css/dev/postcss.config.js index f62884a..48e0498 100644 --- a/assets/css/dev/postcss.config.js +++ b/assets/css/dev/postcss.config.js @@ -8,21 +8,21 @@ module.exports = { require('tailwindcss')(themeDir + 'assets/css/tailwind.config.js'), // Configuration of purgecss for Tailwindcss // see https://tailwindcss.com/docs/controlling-file-size/#setting-up-purgecss - require('@fullhuman/postcss-purgecss')({ - // Specify the paths to all of the template files in your project - content: [ - themeDir + 'layouts/**/*.html', - themeDir + 'exampleSite/content/**/*.html', - 'layouts/**/*.html', - 'content/**/*.html', - 'content/**/*.md', - '**/*.md', - ], - // Include any special characters you're using in this regular expression - defaultExtractor: content => content.match(/[\w-/:]+(?<!:)/g) || [], - fontFace: true, - whitelistPatternsChildren: [/article/] - }), + // require('@fullhuman/postcss-purgecss')({ + // // Specify the paths to all of the template files in your project + // content: [ + // themeDir + 'layouts/**/*.html', + // themeDir + 'exampleSite/content/**/*.html', + // 'layouts/**/*.html', + // 'content/**/*.html', + // 'content/**/*.md', + // '**/*.md', + // ], + // // Include any special characters you're using in this regular expression + // defaultExtractor: content => content.match(/[\w-/:]+(?<!:)/g) || [], + // fontFace: true, + // safelist: [/article/] + // }), require('autoprefixer')({ grid: true }), diff --git a/assets/css/postcss.config.js b/assets/css/postcss.config.js index 47f4e11..b51ea7f 100644 --- a/assets/css/postcss.config.js +++ b/assets/css/postcss.config.js @@ -8,21 +8,21 @@ module.exports = { require('tailwindcss')(themeDir + 'assets/css/tailwind.config.js'), // Configuration of purgecss for Tailwindcss // see https://tailwindcss.com/docs/controlling-file-size/#setting-up-purgecss - require('@fullhuman/postcss-purgecss')({ - // Specify the paths to all of the template files in your project - content: [ - themeDir + 'layouts/**/*.html', - themeDir + 'exampleSite/content/**/*.html', - 'layouts/**/*.html', - 'content/**/*.html', - 'content/**/*.md', - '**/*.md', - ], - // Include any special characters you're using in this regular expression - defaultExtractor: content => content.match(/[\w-/:]+(?<!:)/g) || [], - fontFace: true, - whitelistPatternsChildren: [/article/] - }), + // require('@fullhuman/postcss-purgecss')({ + // // Specify the paths to all of the template files in your project + // content: [ + // themeDir + 'layouts/**/*.html', + // themeDir + 'exampleSite/content/**/*.html', + // 'layouts/**/*.html', + // 'content/**/*.html', + // 'content/**/*.md', + // '**/*.md', + // ], + // // Include any special characters you're using in this regular expression + // defaultExtractor: content => content.match(/[\w-/:]+(?<!:)/g) || [], + // fontFace: true, + // safelist: [/article/] + // }), require('autoprefixer')({ grid: true }), diff --git a/assets/css/tailwind.config.js b/assets/css/tailwind.config.js index ac6d7f2..a2eead4 100644 --- a/assets/css/tailwind.config.js +++ b/assets/css/tailwind.config.js @@ -1,4 +1,11 @@ module.exports = { + purge: { + content: [ + './layouts/**/*.html', + './content/**/*.md', + './content/**/*.html', + ], + }, theme: { fontFamily: { sans: [ @@ -38,7 +45,4 @@ module.exports = { plugins: [ require('@tailwindcss/ui'), ], - future: { - removeDeprecatedGapUtilities: true, - }, } diff --git a/package.json b/package.json index f7dfaf3..86f893a 100644 --- a/package.json +++ b/package.json @@ -9,8 +9,8 @@ "scripts": { "dev": "hugo server --disableFastRender", "dev:example": "hugo server --verbose -s exampleSite --themesDir=../.. --disableFastRender", - "build": "hugo --gc --minify", - "build:example": "hugo --gc --minify -s exampleSite --themesDir=../..", + "build": "NODE_ENV=production hugo --verbose --gc --minify", + "build:example": "NODE_ENV=production hugo --verbose --gc --minify -s exampleSite --themesDir=../..", "start": "hugo --gc" }, "devDependencies": { |