feat(dev): better support for processing tailwind css

- support use tailwind’s most features.
- support write css right next to the components.
This commit is contained in:
Runjuu
2020-10-29 19:14:27 +08:00
parent 7824973abc
commit 22887860df
8 changed files with 1344 additions and 54 deletions

View File

@@ -9,7 +9,8 @@ module.exports = (ctx) => ({
'../resources/static/js/main.js',
// etc.
],
// https://tailwindcss.com/docs/controlling-file-size#setting-up-purgecss
// https://tailwindcss.com/docs/controlling-file-size#understanding-the-regex
// without this we miss keeping eg. `w-1/2`
defaultExtractor: (content) => content.match(/[\w-/:]+(?<!:)/g) || [],
})