Answers for "Could not find the drag and drop manager in the context of ResourceEvents. Make sure to wrap the top-level component of your app with DragDropContext"

0

Could not find the drag and drop manager in the context of ResourceEvents. Make sure to wrap the top-level component of your app with DragDropContext

import React, { Component } from "react";
// import ReactDOM from "react-dom";
import HTML5Backend from "react-dnd-html5-backend";
import { DragDropContext as dragDropContext } from "react-dnd";
import DragBox from "./DragBox";
import DropBox from "./DropBox";

class MainContext extends Component {
  render() {
    return (
      <div style={{ borderStyle: "solid" }}>
        <p style={{ padding: "0px 10px" }}>Main Context</p>
        <DragBox />
        <DropBox />
      </div>
    );
  }
}

module.exports = dragDropContext(HTML5Backend)(MainContext);
Posted by: Guest on June-09-2021

Code answers related to "Could not find the drag and drop manager in the context of ResourceEvents. Make sure to wrap the top-level component of your app with DragDropContext"

Browse Popular Code Answers by Language