Value:
null when no whiteboard session is active.startWhiteboard() has been called.import { View, Text } from "react-native";
import { WebView } from "react-native-webview";
import { useWhiteboard } from "@videosdk.live/react-native-sdk";
function WhiteboardComponent() {
const { whiteboardUrl } = useWhiteboard();
if (!whiteboardUrl) {
return (
<View style={{ flex: 1, alignItems: "center", justifyContent: "center" }}>
<Text>No active whiteboard session</Text>
</View>
);
}
return (
<View style={{ flex: 1 }}>
<WebView source={{ uri: whiteboardUrl }} style={{ flex: 1 }} />
</View>
);
}
export default WhiteboardComponent;
useWhiteboardprovides APIs to start, stop, and access a collaborative whiteboard session within a meeting.