postgrest icon indicating copy to clipboard operation
postgrest copied to clipboard

PostgREST in WebAssembly ?

Open wolfgangwalther opened this issue 3 years ago • 3 comments

Discussed in https://github.com/PostgREST/postgrest/discussions/2353

Originally posted by nileshtrivedi June 28, 2022 Has anyone tried porting PostgREST to WASM binary format? This opens the possibility of deploying PostgREST on edge cloud infra like Deno.com - which can be a lot more convenient and cost-effective.

I'm not familiar with Haskell ecosystem. I couldn't find any discussions about WASM in Stack repo.

wolfgangwalther avatar Aug 28 '22 10:08 wolfgangwalther

Related news https://www.tweag.io/blog/2024-11-21-ghc-wasm-th-ghci/

steve-chavez avatar Nov 22 '24 20:11 steve-chavez

Slightly less related https://github.com/electric-sql/pglite

develop7 avatar Nov 23 '24 19:11 develop7

I imagine running pglite + postgrest in a demo app for our docs entirely in the user's browser.. :thinking:

wolfgangwalther avatar Nov 23 '24 19:11 wolfgangwalther

pglite

I believe pglite doesn't use libpq and has a special way of connecting to the db (ref). I think that we need to support exporting our Plan/Query modules as libraries then convert them to WASM somehow to use postgREST in pglite.

steve-chavez avatar Mar 05 '25 15:03 steve-chavez