Skip to content

Instantly share code, notes, and snippets.

@sendbird-community
Created December 3, 2022 19:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sendbird-community/8a6b9718414bd2383fe51686c10b9c27 to your computer and use it in GitHub Desktop.
Save sendbird-community/8a6b9718414bd2383fe51686c10b9c27 to your computer and use it in GitHub Desktop.
An example of how to use the CreateChannel module
import CreateChannel from '@sendbird/uikit-react/CreateChannel';
import { CreateChannelProvider, useCreateChannel } from '@sendbird/uikit-react/CreateChannel/context';
const MyComponent = () => {
const createChannelState = useCreateChannel();
return (
...render custom component
);
};
<CreateChannelProvider>
<MyComponent />
<CreateChannelProvider/>
const StepOneView = () => {
const createChannelState = useCreateChannel();
return (
...render custom component
);
};
<CreateChannel
renderStepOne={StepOneView}
/>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment