rocicorp / replicache

Realtime Sync for Any Backend Stack
https://doc.replicache.dev
1.04k stars 37 forks source link

Introduction docs error #987

Closed jesper-bylund closed 2 years ago

jesper-bylund commented 2 years ago

I'm walking through the integration guide and found an error:

Screenshot 2022-04-30 at 12 45 41

There's a bit of ambiguity here, since there are a bunch of connection strings on supabase.

Screenshot 2022-04-30 at 12 46 20

If I use the "PSQL" one, which to me seems like the one intended you get the following error:

Error: connect ECONNREFUSED 127.0.0.1:5432
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1161:16) {
  errno: -61,
  code: 'ECONNREFUSED',
  syscall: 'connect',
  address: '127.0.0.1',
  port: 5432
}

That connection IP is ofc incorrect, but I'm not sure what the instruction intends be to do.

jesper-bylund commented 2 years ago

Found the solution. What is SHOULD say is:

Head over to Supabase and create a free account and an empty database. Then add Supabase's PSQL connection string to your environment. You can get it from your Supabase project by clicking on ⚙️ (Gear/Cog) > Database > Connection String. Chose the URI option (it should look like: postgresql://postgres:[YOUR-PASSWORD]@db.[ID].supabase.co:5432/postgres).

phritz commented 2 years ago

Thanks @jesper-bylund I will update the docs this coming week.

aboodman commented 2 years ago

Jasper, just to be clear the integration guide is only necessary if you plan to integrate Replicache into an existing backend. If you are starting new with Replicache, you can fork the starter app and it will be a lot easier.

We plan to make this more clear in the docs next week too.

On Sat, Apr 30, 2022 at 11:22 AM Phritz @.***> wrote:

Thanks @jesper-bylund https://github.com/jesper-bylund I will update the docs this coming week.

— Reply to this email directly, view it on GitHub https://github.com/rocicorp/replicache/issues/987#issuecomment-1114031976, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAATUBEQ33HD27AIMWFMKW3VHV25JANCNFSM5UYF5YSA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

-- a (phone)

jesper-bylund commented 2 years ago

@aboodman It's jEsper.

And thank you, but that's exactly what I was doing!

aboodman commented 2 years ago

jEsper

Apologies, typo on phone.