Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/frontend-collective/react-sortable-tree-theme-full-node-drag
Full node drag theme for react-sortable-tree
https://github.com/frontend-collective/react-sortable-tree-theme-full-node-drag
Last synced: 8 days ago
JSON representation
Full node drag theme for react-sortable-tree
- Host: GitHub
- URL: https://github.com/frontend-collective/react-sortable-tree-theme-full-node-drag
- Owner: frontend-collective
- License: mit
- Created: 2017-12-03T02:35:46.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-05-26T10:54:20.000Z (over 1 year ago)
- Last Synced: 2024-07-13T05:46:13.217Z (4 months ago)
- Language: JavaScript
- Size: 684 KB
- Stars: 38
- Watchers: 2
- Forks: 53
- Open Issues: 15
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# React Sortable Tree Full Node Drag Theme
## Features
* No drag handles. You can click anywhere on a node to drag it.## Usage
```sh
npm install --save react-sortable-tree-theme-full-node-drag
``````jsx
import React, { Component } from 'react';
import SortableTree from 'react-sortable-tree';
import FileExplorerTheme from 'react-sortable-tree-theme-full-node-drag';export default class Tree extends Component {
constructor(props) {
super(props);this.state = {
treeData: [{ title: 'src/', children: [ { title: 'index.js' } ] }],
};
}render() {
return (
this.setState({ treeData })}
theme={FileExplorerTheme}
/>
);
}
}
```