tailwindcss
tailwindcss copied to clipboard
Cannot access the application: defu__WEBPACK_IMPORTED_MODULE_3__ is not a function
Version
@nuxtjs/tailwindcss: v5.1.2 nuxt: v2.15.8
Reproduction Link
https://codesandbox.io/s/tailwindcss-module-issue-defu-jqhlf6
It is working fine with @nuxtjs/tailwindcss v5.0.4. Another user seems to get the same error, as seen on StackOverflow: https://stackoverflow.com/questions/72409854/defu-webpack-imported-module-3-is-not-a-function-nuxt-auth
Steps to reproduce
- Add
@nuxtjs/auth-next
dependency (version5.0.0-1648802546.c9880dc
) - Configure strategies in
nuxt.config.js
- Run dev server and open Nuxt application in the browser
What is Expected?
- Application is running properly
What is actually happening?
- Getting an error message:
defu__WEBPACK_IMPORTED_MODULE_3__ is not a function
Getting the same error while installing @nuxt/content
to an existing project.
Same here on my project. I am also adding @nuxt/content
to an existing project.
I think I fixed it in the short term. You can install an older version with the command yarn add @nuxt/[email protected]
as the current install command installs a version of @nuxt/content
that requires 3.0.0-rc.3
and I'm using Nuxt 2
I opened a issue on the Nuxt content repo here: https://github.com/nuxt/content/issues/1270
I also have the same problem with @nuxtjs/auth-next. I did what @Unieveth said and installed version 4.9.1. It did work but I still hope this will be fixed soon.
I also have the same problem with @nuxtjs/auth-next. I did what @Unieveth said and installed version 4.9.1. It did work but I still hope this will be fixed soon.
Same situation here. Reverted to V4
any update here? I am not using nuxt content... and am experiencing this error
Any update on this?
It seems to be a Problem with webpack and or the package defu. I've solved it by installing defu in version 5.0.1
.
same issue! This problem occurs after project initialization.
Nuxt 2 + Typescript + tailwindCSS + chakraUI + yarn + Nuxt Content
$ nuxt
FATAL defu is not a function
at ModuleContainer.module.exports (node_modules/@chakra-ui/nuxt/lib/module.js:20:32)
at ModuleContainer.addModule (node_modules/@nuxt/core/dist/core.js:239:34)
at node_modules/@nuxt/utils/dist/utils.js:639:43
at async ModuleContainer.ready (node_modules/@nuxt/core/dist/core.js:55:5)
at async Nuxt._init (node_modules/@nuxt/core/dist/core.js:478:5)
Still no fix by nuxt?
In nuxt.config.js add:
build: {
transpile: [
'defu'
]
}
as seen on StackOverflow: https://stackoverflow.com/questions/72414023/defu-webpack-imported-module-3-is-not-a-function
Closing this issue as it is believed to be resolved/stale now - please feel free to comment if it is still an issue in the latest version of the module.
We're facing this same issue with nuxt 2.17.0
defu__WEBPACK_IMPORTED_MODULE_3__ is not a function
how can i solve this problem
I solved it by this
In nuxt.config.js add:
build: { transpile: [ 'defu' ] }
as seen on StackOverflow: https://stackoverflow.com/questions/72414023/defu-webpack-imported-module-3-is-not-a-function