Skip to content

Commit

Permalink
Merge pull request #70 from tightenco/kdd/use-tailwind-purge
Browse files Browse the repository at this point in the history
Replace manual purgeCss with Tailwind's built-in version
  • Loading branch information
damiani authored Aug 12, 2020
2 parents 1c5b750 + 7ceca51 commit ace974d
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 6 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"highlight.js": "^9.13.1",
"laravel-mix": "^4.0.0||^5.0.0",
"laravel-mix-jigsaw": "^1.0.0",
"laravel-mix-purgecss": "^4.0.0||^5.0.0",
"sass": "^1.15.2",
"sass-loader": "^7.1.0",
"tailwindcss": "^1.0.4",
Expand Down
16 changes: 16 additions & 0 deletions tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,20 @@
module.exports = {
purge: {
content: [
'source/**/*.html',
'source/**/*.md',
'source/**/*.js',
'source/**/*.php',
'source/**/*.vue',
],
options: {
whitelist: [
/language/,
/hljs/,
/mce/,
],
},
},
theme: {
extend: {
fontFamily: {
Expand Down
5 changes: 0 additions & 5 deletions webpack.mix.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
const mix = require('laravel-mix');
require('laravel-mix-jigsaw');
require('laravel-mix-purgecss');

mix.disableSuccessNotifications();
mix.setPublicPath('source/assets/build');
Expand All @@ -16,9 +15,5 @@ mix.js('source/_assets/js/main.js', 'js')
require('tailwindcss'),
],
})
.purgeCss({
content: ['source/**/*.html', 'source/**/*.md', 'source/**/*.js', 'source/**/*.php', 'source/**/*.vue'],
whitelistPatterns: [/language/, /hljs/, /mce/],
})
.sourceMaps()
.version();

0 comments on commit ace974d

Please sign in to comment.