# Supabase.js 1.0

[Supabase](https://yomu.fyi/company/supabase) · Paul Copplestone · Oct 30, 2020

**Type:** Announcement

## Summary

Supabase has launched Supabase.js 1.0, updating its client library ecosystem with breaking API changes, scalability enhancements, and new documentation tooling. The release introduces native TypeScript implementations across all underlying sub-libraries, including supabase-js, postgrest-js, gotrue-js, and realtime-js, which also enables auto-generated reference docs. In response to community feedback, database and authentication operations now return structured error objects alongside data payloads instead of throwing runtime exceptions. Realtime client scalability is improved by consolidating multiple active subscriptions into a single socket connection per Supabase client. Additionally, the release updates authentication workflows via the newly created gotrue-js library to support third-party logins and OAuth providers alongside revised method names.

## Context

Community feedback and the requirement to coordinate multiple underlying open-source sub-libraries motivated structural, ergonomic, and performance updates across the Supabase JavaScript library.

## Approach / What changed

Supabase released version 1.0 of supabase-js, rewriting all sub-libraries natively in TypeScript, switching error handling from throwing exceptions to returning error objects, reducing realtime socket overhead to one connection per client, and adding gotrue-js for authentication.

## Takeaways

- Supabase.js 1.0 shifts error handling from throwing runtime exceptions to returning error objects alongside data, allowing inline error evaluation.
- Realtime connection scalability is improved by sharing a single socket connection per Supabase client across all subscriptions rather than opening a connection per subscription.
- All core sub-libraries—supabase-js, postgrest-js, gotrue-js, and realtime-js—are natively written in TypeScript, facilitating auto-generated reference documentation.

**Tags:** [Authentication](https://yomu.fyi/topic/authentication), [Developer Experience](https://yomu.fyi/topic/developer-experience), [Open Source](https://yomu.fyi/topic/open-source), [Scalability](https://yomu.fyi/topic/scalability), [TypeScript](https://yomu.fyi/topic/typescript)

[Read original post](https://supabase.com/blog/improved-dx)
