Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: allow nuxt.options.pages to be unset #747

Merged
merged 1 commit into from
Nov 2, 2023
Merged

fix: allow nuxt.options.pages to be unset #747

merged 1 commit into from
Nov 2, 2023

Conversation

maddysrc
Copy link
Contributor

@maddysrc maddysrc commented Nov 2, 2023

Weirdly enough the default isn't always set. The default is actually equal to "is the pages directory not empty" but assuming undefined means true is fine in this case as its only used to add a glob.

I also noticed use of nuxt.options.dir.modules causes an error to be logged to console, but removing that would be a breaking change now.

[16:13:24]  ERROR  This module cannot be imported in the Vue part of your app. [importing nuxt/kit from modules/my-module.ts]

@ineshbose
Copy link
Collaborator

ineshbose commented Nov 2, 2023

I also noticed use of nuxt.options.dir.modules causes an error to be logged to console

That's a good point; Tailwind JIT is picking up nuxt/kit string and causes that warning - I am up for removing modules, as it can be added by users' configs and merged using defu.

As modules was never added in the content paths by this module in the first place (before 6.9.0), I don't believe it'll be a breaking change.

@maddysrc
Copy link
Contributor Author

maddysrc commented Nov 2, 2023

As modules was never added in the content paths by this module in the first place (before 6.9.0), I don't believe it'll be a breaking change.

As it got a proper release on npm, even for just a day, I would say it is. I'm up to remove the pattern in this or another PR though.

@ineshbose
Copy link
Collaborator

I've opened a separate PR for that #748 - let's take discussion there if we want to continue.

@ineshbose
Copy link
Collaborator

Thanks for this PR though - this is a brilliant spot! 😄

@atinux atinux merged commit 3d97544 into nuxt-modules:main Nov 2, 2023
1 check passed
@maddysrc maddysrc deleted the fix-pages-regression branch November 2, 2023 16:09
Copy link

netlify bot commented Mar 27, 2024

‼️ Deploy request for nuxt-tailwindcss rejected.

Name Link
🔨 Latest commit 4052e11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants