question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

tailwind.config.js completely ignored

See original GitHub issue

Version

@nuxtjs/tailwindcss: v5.3.1 nuxt: v3.0.0-rc6

After upgrading my nuxt blog to v3 (+content and image modules), the only thing that is still completely broken is styling. I found out that my tailwind.config.js is not being used at all. If I introduce a syntax error in the file on purpose, nuxt dev server still starts without a problem (except the broken styling). It doesn’t matter if I explicitly configure the config path with tailwindcss: { configPath: '~/tailwind.config.js' } or not (as per issue #500).

The nuxt v2 version works fine with the same @nuxtjs/tailwindcss version.

Any ideas on how I could debug this?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:16 (2 by maintainers)

github_iconTop GitHub Comments

4reactions
SilvioDoMinecommented, Aug 10, 2022

Same problem here, extended colors dont work

1reaction
varnacommented, Aug 19, 2022

For anyone that encounters this issue, the temporary fix is transferring the config file into nuxt.conf.js instead:

<nuxt.conf.js>

export default defineNuxtConfig({
    modules: ['@nuxtjs/tailwindcss'],
    tailwindcss: {
        config: {
           ... <tailwind.conf.js goes here> ...
        }
    }
});

And here is a TS version of nuxt.config.ts:

import tailwindTypography from '@tailwindcss/typography'
import tailwindForms from '@tailwindcss/forms'

export default {
  modules: ['@nuxtjs/tailwindcss'],
  tailwindcss: {
    config: {
      plugins: [tailwindTypography, tailwindForms]
    }
  }
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Laravel Mix (v6.16.0) ignores tailwind.config.js (v1.2.0) settings
My only problem is, that all changes I made in tailwind.config.js are ignored. The files are recompiled ( npm run watch ), but...
Read more >
Configuration - Tailwind CSS
A guide to configuring and customizing your Tailwind installation.
Read more >
babel config ignored · Issue #395 - GitHub
Hello, I am receiving the error Tailwind CSS: 'import' and 'export' may appear only with 'sourceType: module' (1:0) after switching to ES6 syntax...
Read more >
How to Set Up Next.js With Tailwind - Jake Prins
It's a utility-first framework, which means it doesn't focus on predesigned components like buttons, cards, and alerts. It provides low-level utility classes ...
Read more >
gatsby-plugin-purgecss
Define options in gatsby-config.js , not purgecss.config.js . ... Whitelist the required selectors or completely ignore files using Whitelist Solutions ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found