Content-Length: 295944 | pFad | http://github.com/zyzo/react-dnd-mouse-backend

7B GitHub - zyzo/react-dnd-mouse-backend: Mouse Backend for react-dnd library
Skip to content

zyzo/react-dnd-mouse-backend

Repository files navigation

react-dnd-mouse-backend

http://zyzo.github.io/react-dnd-mouse-backend/

npm version

Mouse Backend for React Drag and Drop library http://gaearon.github.io/react-dnd

Usage

import { DragDropContext } from 'react-dnd'
import MouseBackEnd from 'react-dnd-mouse-backend'

const App = {...}

const AppContainer = DragDropContext(MouseBackEnd)(App)

Playground

First, prepare the playground:

cd example;
yarn; yarn start

Then head to http://localhost:3030/ to start some fun drag and dropping.

Development

First, install the project locally:

git clone git@github.com:zyzo/react-dnd-mouse-backend.git
cd react-dnd-mouse-backend; npm install
# (Optional) prepare example project
cd example; npm install

Then, link react-dnd-mouse-backend to example project (or your js project):

# in ./react-dnd-mouse-backend
npm link
cd example; npm link react-dnd-mouse-backend

Finally you can begin to make changes in src folder, and rebuild the lib:

npm run build

Credits

Inspired by HTML5 Backend & Touch Backend to support only mouse events, which work much better in some cases, like svg.









ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/zyzo/react-dnd-mouse-backend

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy