nuxt-modules / supabase

Supabase module for Nuxt.
https://supabase.nuxtjs.org
MIT License
733 stars 129 forks source link

Not working in ssr mode, works fine with ssr:false #291

Closed TechAkayy closed 1 year ago

TechAkayy commented 1 year ago

Version

@nuxtjs/supabase: 1.1.3 nuxt: 3.7.4

Reproduction Link

https://github.com/TechAkayy/supa-nuxt-vuetify-tailwindcss

Steps to reproduce

Set up the environment variables cp .env.example .env

What is Expected?

What is actually happening?

500
Cannot find module './lib/websocket' Require stack: - /Users/techakayy/Tests/reproductions/supa-nuxt-vuetify-tailwindcss/websocket

at Module._resolveFilename (node:internal/modules/cjs/loader:995:15)
at Module._load (node:internal/modules/cjs/loader:841:27)
at Module.require (node:internal/modules/cjs/loader:1061:19)
at require (node:internal/modules/cjs/helpers:103:18)
at ./websocket:1:18
at ViteNodeRunner.directRequest (./node_modules/vite-node/dist/client.mjs:341:11)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async ViteNodeRunner.cachedRequest (./node_modules/vite-node/dist/client.mjs:197:14)
at async ViteNodeRunner.dependencyRequest (./node_modules/vite-node/dist/client.mjs:231:12)
at async ./node_modules/@supabase/realtime-js/dist/module/RealtimeClient.js:1:31

Dependencies Info

Dependencies Info _Run `npx nuxi info` and `pnpm list` (or `npm list`) and provide the output:_ ``` - Operating System: `Darwin` - Node Version: `v18.12.1` - Nuxt Version: `3.7.4` - CLI Version: `3.9.0` - Nitro Version: `2.6.3` - Package Manager: `npm@8.19.2` - Builder: `-` - User Config: `modules` - Runtime Modules: `vuetify-nuxt-module@0.5.14`, `@nuxtjs/supabase@1.1.3` - Build Modules: `-` pg-nuxt-vuetify-tailwindcss@0.0.0 /Users/techakayy/Tests/reproductions/supa-nuxt-vuetify-tailwindcss ├── @mdi/js@7.3.67 ├── @nuxt/eslint-config@0.1.1 ├── @nuxtjs/supabase@1.1.3 ├── @types/node@20.8.4 ├── eslint-config-prettier@8.10.0 ├── eslint@8.51.0 ├── npm-run-all@4.1.5 ├── nuxt@3.7.4 ├── prettier@2.8.8 ├── sass@1.69.2 ├── typescript@5.2.2 ├── vite-plugin-vuetify@1.0.2 ├── vuetify-nuxt-module@0.5.14 └── vuetify@3.3.21 ```
TechAkayy commented 1 year ago

Not sure if its related, but I found the same error reported here - https://github.com/supabase/supabase/issues/7672#issuecomment-1743861226

TechAkayy commented 1 year ago

Fixed at vuetify-nuxt-module end - https://github.com/userquin/vuetify-nuxt-module/issues/123.