Skip to content

Commit

Permalink
fix: don't require build.tailwind.css in postcss filter
Browse files Browse the repository at this point in the history
  • Loading branch information
cossssmin committed Oct 2, 2022
1 parent fb28b23 commit 923f24b
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/generators/postcss.js
@@ -1,4 +1,3 @@
const path = require('path')
const {get} = require('lodash')
const postcss = require('postcss')
const postcssImport = require('postcss-import')
Expand All @@ -7,10 +6,8 @@ const mergeLonghand = require('postcss-merge-longhand')

module.exports = {
process: async (css = '', maizzleConfig = {}) => {
const userFilePath = get(maizzleConfig, 'build.tailwind.css', path.join(process.cwd(), 'src/css/tailwind.css'))

return postcss([
postcssImport({path: path.dirname(userFilePath)}),
postcssImport(),
postcssNested(),
maizzleConfig.env === 'local' ? () => {} : mergeLonghand(),
...get(maizzleConfig, 'build.postcss.plugins', [])
Expand Down

0 comments on commit 923f24b

Please sign in to comment.