Supabase Launches @supabase/server to Simplify SSR Authentication Templates

iconKuCoinFlash
Share
Share IconShare IconShare IconShare IconShare IconShare IconCopy
AI summary iconSummary

expand icon
Supabase launched the @supabase/server npm package, version 0.1.4, on April 21 (UTC+8). It simplifies SSR authentication and cookie management for frameworks such as Next.js. The tool includes a withSupabase function to streamline access policies and client configuration. As CFT regulations tighten, developers need efficient tools to maintain compliance with liquidity and crypto market requirements. Supabase co-founder Paul Copplestone noted that the package is in an early stage, with framework-specific adapters currently in development.

ME News reports that on April 21 (UTC+8), according to monitoring by Beating, Supabase has released the npm package @supabase/server, version 0.1.4, under the MIT license. This package consolidates the creation of the Supabase client, cookie synchronization, and authentication session management for server-side rendering, API routes, and edge functions—eliminating the need for developers to manually piece these together. It provides a higher-order function called withSupabase. Developers pass in an access policy (e.g., allow: 'user' to permit only authenticated users), and the returned handler attaches the configured Supabase client to ctx.supabase, allowing business logic to directly query the database via ctx.supabase.from('todos').select(). Supabase co-founder Paul Copplestone announced the release on X, noting that this is an early version and that the team is actively seeking testers and feedback, while also developing adapters for various frameworks. Previously, integrating Supabase into SSR frameworks like Next.js required developers to manually handle cookie retrieval, session refreshing, and client propagation—repeatedly criticized by the community as boilerplate overhead. (Source: BlockBeats)

Disclaimer: The information on this page may have been obtained from third parties and does not necessarily reflect the views or opinions of KuCoin. This content is provided for general informational purposes only, without any representation or warranty of any kind, nor shall it be construed as financial or investment advice. KuCoin shall not be liable for any errors or omissions, or for any outcomes resulting from the use of this information. Investments in digital assets can be risky. Please carefully evaluate the risks of a product and your risk tolerance based on your own financial circumstances. For more information, please refer to our Terms of Use and Risk Disclosure.