Skip to content

Commit

Permalink
fix: use nuxt resolver to import tailwind.config.js (#286)
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 authored Mar 10, 2021
1 parent 2caa0bc commit 62526cf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions example/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export default {
}
2 changes: 1 addition & 1 deletion lib/module.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ module.exports = async function (moduleOptions) {
let tailwindConfig = {}
if (await pathExists(configPath)) {
clearModule(configPath)
tailwindConfig = require(configPath)
tailwindConfig = nuxt.resolver.requireModule(configPath)
logger.info(`Merging Tailwind config from ~/${relative(this.options.srcDir, configPath)}`)
}
// Merge with our default purgecss default
Expand Down

0 comments on commit 62526cf

Please sign in to comment.