Nuxt 3 dayjs module

I try to use dayjs module in my pnpm monorepo i follow all the documentation but when i use dayjs i obtain error in my console SyntaxError: The requested module '/_nuxt/@fs/name/test/Documents/firstname/app/node_modules/.pnpm/[email protected]/node_modules/dayjs/dayjs.min.js?v=8db2d171' does not provide an export named 'default' (at dayjs.imports.mjs:3:8) config:
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
runtimeConfig: {
API_URL: "http://localhost:3333",
public: {
API_URL: "http://localhost:3333",
},
},
devtools: { enabled: true },
modules: [
"dayjs-nuxt",
"@nuxt/ui",
"@vee-validate/nuxt",
"@nuxtjs/tailwindcss",
"@nuxt/image",
"nuxt-icon",
],
dayjs: {
locales: ["en", "fr"],
plugins: ["relativeTime", "utc", "timezone"],
defaultLocale: "fr",
defaultTimezone: "Europe/Paris",
},
});
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
runtimeConfig: {
API_URL: "http://localhost:3333",
public: {
API_URL: "http://localhost:3333",
},
},
devtools: { enabled: true },
modules: [
"dayjs-nuxt",
"@nuxt/ui",
"@vee-validate/nuxt",
"@nuxtjs/tailwindcss",
"@nuxt/image",
"nuxt-icon",
],
dayjs: {
locales: ["en", "fr"],
plugins: ["relativeTime", "utc", "timezone"],
defaultLocale: "fr",
defaultTimezone: "Europe/Paris",
},
});
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server