-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
When using the hook useCustomSubscription twice with the same subscription, loading property keeps changing value indefinitely.
Expected behavior
Whenever the hook is called, it should show loading true initially and when data comes, it should show loading false without ever changing it's value again.
Additional context
Code used to reproduce the error:
export const SCREENSHARE = `
subscription Screenshare {
screenshare {
stream
}
}
`
export const useScreenshare = (pluginApi: PluginApi) => {
const response = pluginApi.useCustomSubscription!<ScreenshareSubscriptionResult>(
SCREENSHARE,
);
console.log(new Date().toISOString(), JSON.stringify({ response }));
return response;
};then the hook must be used in 2 different components.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working