npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@real-life-stack/supabase-connector

v0.1.2

Published

Nativer Supabase-Connector: PostgREST für Queries/Writes, Supabase Realtime (`postgres_changes`) für live `observe()` — dieselbe Reaktivität wie beim WoT-Connector. Claim-Modus `authoritative` (Spec 08): das `trusted`-Verdikt stützt sich auf die serversei

Readme

@real-life-stack/supabase-connector

Nativer Supabase-Connector: PostgREST für Queries/Writes, Supabase Realtime (postgres_changes) für live observe() — dieselbe Reaktivität wie beim WoT-Connector. Claim-Modus authoritative (Spec 08): das trusted-Verdikt stützt sich auf die serverseitigen RLS-Policies in supabase/migrations/0001_rls_schema.sql (INSERT bindet created_by an auth.uid(), ein Trigger macht Identitätsfelder unveränderlich), nicht auf Client-Code.

Lokal starten

Voraussetzung: Docker.

# Im Repo-Root — startet Postgres, PostgREST, GoTrue, Realtime, Studio
npx supabase start

supabase start gibt API URL, anon key und service_role key aus. Migrationen aus supabase/migrations/ werden automatisch angewendet.

Reference-App dagegen fahren

cd apps/reference
VITE_SUPABASE_URL=http://127.0.0.1:54321 \
VITE_SUPABASE_ANON_KEY=<anon key> \
VITE_DEFAULT_CONNECTOR=supabase \
pnpm dev

Alternativ per URL-Param: http://localhost:5173/?connector=supabase&dev. v1 meldet sich automatisch anonym an (Session überlebt Reloads); ein echter Login-Screen (E-Mail/Passwort) ist Folgearbeit.

Tests

  • Unit-Tests (pnpm test): laufen überall — der echte Connector gegen einen In-Memory-Fake des supabase-js-Subsets. Der Fake ist NICHT der Schiedsrichter für PostgREST-Semantik, sondern prüft Wiring: Autor-Bindung, Mapping, Realtime-Refresh, Relation-Store, Gruppen-Scoping.
  • Live-Contract-Suite (tests/data-interface-contract.live.test.ts): die geteilte DataInterface-Contract-Suite plus RLS-Grenztests gegen eine echte Instanz. Ohne Env-Variablen skippt sie.
SUPABASE_URL=http://127.0.0.1:54321 \
SUPABASE_ANON_KEY=<anon key> \
SUPABASE_SERVICE_ROLE_KEY=<service_role key> \
pnpm --filter @real-life-stack/supabase-connector test

Vertragsgrenzen (dokumentierte Abweichungen)

  • hasField nutzt NOT data->key IS NULL: ein Feld mit explizitem JSON-null zählt hier als abwesend, während matchesFilter (key in data) es als vorhanden zählt. Feldnamen sind auf [A-Za-z0-9_-] beschränkt (alles andere wirft — fail closed statt Query-Injection).
  • getAuthMethods: anonymous, email (signInWithPassword), email-signup (signUp, optional displayName).
  • Fixture-Pfad (allowFixtureAuthors: true, für Tests/Tooling mit service_role-Key): behält fremde Autoren und VERLIERT dafür verifyRecordClaim — wie bei Local/Mock.