Whereby in Next.js
Next.js is a popular framework for React and is rendered server-side. The Whereby browser-sdk relies on browser specific API’s to work so due to this, usage with Next.js has some challenges.
Provider
"use client";
import * as React from "react";
import { WherebyProvider } from "@whereby.com/browser-sdk/react";
function Provider({ children }: { children: React.ReactNode }) {
return (
<WherebyProvider>
<>{children}</>
</WherebyProvider>
);
}
export default Provider;
The room component
Using the room component
Last updated
Was this helpful?

