unjs / cookie-es

🍪 Cookie and Set-Cookie parser and serializer
Other
149 stars 10 forks source link

Bug when build #48

Closed Master2IT closed 3 months ago

Master2IT commented 3 months ago

Environment

Node v20

"dependencies": { "@babel/preset-typescript": "^7.15.0", "@bachdgvn/vue-otp-input": "^1.0.8", "@nuxtjs/axios": "^5.13.6", "@nuxtjs/eslint-config-typescript": "^8.0.0", "@nuxtjs/proxy": "^2.1.0", "@nuxtjs/pwa": "^3.3.5", "@tailwindcss/typography": "^0.5.2", "@types/lodash": "^4.14.171", "@types/moment-jalaali": "^0.7.5", "cookie-es": "^1.2.2", "core-js": "^3.25.3", "lodash": "^4.17.21", "moment": "2.25.1", "moment-jalaali": "^0.9.2", "moment-locales-webpack-plugin": "^1.2.0", "nuxt": "^2.17.3", "nuxt-i18n": "^6.28.1", "nuxt-property-decorator": "^2.9.1", "nuxt-route-meta": "^3.0.0", "nuxt-viewport": "^2.0.3", "sass": "^1.57.1", "sass-loader": "^10.1.1", "socket.io-client": "^4.7.2", "toastr": "^2.1.4", "vee-validate": "^3.4.14", "vue": "^2.7.10", "vue-2-breadcrumbs": "^0.8.1", "vue-color": "^2.8.1", "vue-persian-datetime-picker": "2.4.1", "vue-select": "^3.16.0", "vue-server-renderer": "^2.7.10", "vue-template-compiler": "^2.7.10", "vue-toastification": "^1.7.14", "vue2-editor": "^2.10.3" }, "devDependencies": { "@nuxt/bridge": "^3.2.0", "@nuxt/types": "^2.15.8", "@nuxt/typescript-build": "^2.1.0", "@types/vue-color": "^2.4.4", "autoprefixer": "^10.4.15", "daisyui": "^4.10.2", "nuxi": "^3.11.1", "postcss": "^8.4.28", "tailwindcss": "^3.3.3" },

Describe the bug

Recently, I've been encountering this issue when I try to build the project (nuxt2).

image

Additional context

No response

Logs

No response

pi0 commented 3 months ago

It seems a very old version of webpack in nuxt v2 cannot understand modern syntax. sorry nothing we can fix in cookie-es since we target modern runtimes. I suggest to seek for support via nuxt v2 LTS.

Master2IT commented 3 months ago

I downgraded the @nuxt/bridge package, and then fixed the issues.

pi0 commented 3 months ago

/cc @danielroe