Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/blocks/deps.ts>supabase.RealtimeChannel#unsubscribe

Git-based Visual CMS for Deno, </> htmx and Tailwind apps. Deploy on any Deno-compatible host.
Go to Latest
method supabase.RealtimeChannel.prototype.unsubscribe
Re-export
import { supabase } from "https://deno.land/x/blocks@1.72.0/deps.ts";
const { RealtimeChannel } = supabase;

Leaves the channel.

Unsubscribes from server events, and instructs channel to terminate on server. Triggers onClose() hooks.

To receive leave acknowledgements, use the a receive hook to bind to the server ack, ie: channel.unsubscribe().receive("ok", () => alert("left!") )

Parameters

optional
timeout: number

Returns

Promise<"ok" | "timed out" | "error">