We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, could you add a more verbose example? I have no idea how to use this component in my app, here is my attempt but doesn't work:
const GridContainer = (props) => { return ( <DndProvider backend={HTML5Backend}> <GridProvider items={props.items}> <GridContent {...props}/> </GridProvider> </DndProvider> ) } export default withDndContext(GridContainer);
Thanks!
The text was updated successfully, but these errors were encountered:
hi @leefsmp . It's supposed to wrap the component down in the component tree where the components up the tree may have already used DndContext.
const _GridContent = withDndContext(GridContent) const GridContainer = (props) => { return ( <DndProvider backend={HTML5Backend}> <GridProvider items={props.items}> <_GridContent {...props}/> // parent component DndProvider has set up DnDContext </GridProvider> </DndProvider> ) } export default GridContainer;
i.e. apply withDndContext HOC to the inner component rather than the outer component
Sorry, something went wrong.
No branches or pull requests
Hi, could you add a more verbose example? I have no idea how to use this component in my app, here is my attempt but doesn't work:
Thanks!
The text was updated successfully, but these errors were encountered: