Description: Postgres WASM by Snaplet and Supabase
2022-10-03
•
11 minute read
Mark Burggraf avatar
Mark Burggraf
Engineering
Postgres WASM by Snaplet and Supabase
Today we're open sourcing postgres-wasm with our friends at Snaplet.
postgres-wasm is a PostgreSQL server that runs inside a browser. It provides a full suite of features, including persisting state to browser, restoring from pg_dump, and logical replication from a remote database.
We're not the first to run Postgres in the browser - that title belongs to the team at Crunchy Data who shared their version of this on HN a month ago. It's awesome, and we wanted an open source version, so we teamed up with Snaplet build it. Let's explore how it's built, and some extra features we've added.
🐈 Who's Snaplet?
Snaplet gives developers production-accurate data and preview databases that they can code against, so they can focus on shipping.
Checkout out how you can use Snaplet to clone Supabase environments.
Demo
Before we get into the technical details, try it out yourself (warning: it will download ~30MB):
# From Snaplet Repo
git clone git@github.com:snaplet/postgres-wasm.git
cd postgres-browser/packages/pg-browser
npx serve
# From Supabase Fork
git clone git@github.com:supabase-community/postgres-wasm.git
cd postgres-wasm
git checkout web
cd packages/supabrowser
npx serve
{'label-name': 'WebAssembly', 'label-description': 'Technology that enables running high-performance applications in web browsers.', 'confidence': 76.53}
Title: Postgres WASM by Snaplet and Supabase
Description: Postgres WASM by Snaplet and Supabase 2022-10-03 • 11 minute read Mark Burggraf avatar Mark Burggraf Engineering
Postgres WASM by Snaplet and Supabase
Today we're open sourcing postgres-wasm with our friends at Snaplet.
postgres-wasm is a PostgreSQL server that runs inside a browser. It provides a full suite of features, including persisting state to browser, restoring from pg_dump, and logical replication from a remote database.
We're not the first to run Postgres in the browser - that title belongs to the team at Crunchy Data who shared their version of this on HN a month ago. It's awesome, and we wanted an open source version, so we teamed up with Snaplet build it. Let's explore how it's built, and some extra features we've added.
🐈 Who's Snaplet?
Snaplet gives developers production-accurate data and preview databases that they can code against, so they can focus on shipping.
Checkout out how you can use Snaplet to clone Supabase environments.
Demo
Before we get into the technical details, try it out yourself (warning: it will download ~30MB):
wasm.supabase.com
Postgres inside a browser
To run it locally:
And open a browser at localhost:3000.
URL: https://supabase.com/blog/postgres-wasm
Suggested labels
{'label-name': 'WebAssembly', 'label-description': 'Technology that enables running high-performance applications in web browsers.', 'confidence': 76.53}