Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ahrefs/melange-react-dnd
https://github.com/ahrefs/melange-react-dnd
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/ahrefs/melange-react-dnd
- Owner: ahrefs
- License: mit
- Created: 2018-01-31T18:23:42.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-03-29T04:01:10.000Z (10 months ago)
- Last Synced: 2024-12-15T00:50:51.608Z (about 1 month ago)
- Language: Makefile
- Size: 669 KB
- Stars: 14
- Watchers: 3
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Melange bindings for react-dnd
[Melange](https://melange.re) bindings for [react-dnd](https://github.com/react-dnd/react-dnd).
## Status
🚧 Not everything is supported yet; Unstable; Doesn't follow semver; 🚧
Feel free to create an issue or PR.
## Install
Install [opam](https://opam.ocaml.org/) package manager.
Then:
```
opam pin add melange-react-dnd.dev git+https://github.com/ahrefs/melange-react-dnd.git#master
```The bindings support the following versions of the `react-dnd` and `react-dnd-html5-backend`
npm packages, which should be installed separately, together with `react` and `react-dom`:```json
"dependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-dnd": "^14.0.3",
"react-dnd-html5-backend": "^14.0.1"
}
```# Setup
Add `melange-react-dnd` to the `libraries` in your `dune` file:
```dune
; ...
(libraries melange-react-dnd)
; ...
```## TODO
* [ ] DragLayer
* [x] Recreate some examples from react-dnd docs## Usage
Please take a look at [examples](https://github.com/ahrefs/melange-react-dnd/tree/master/examples).
To run demo:Run `make watch` for Melange compiler watcher.
Run `make serve` to interact with the example in the browser (`localhost:8080`).