importReact,{FC,useState}from"react";import{ReactSortable}from"react-sortablejs";interfaceItemType{id:number;name:string;}exportconstBasicFunction:FC=(props)=>{const[state,setState]=useState<ItemType[]>([{id:1,
importReact,{FC,useState}from"react";import{ReactSortable}from"react-sortablejs";interfaceItemType{id:number;name:string;}exportconstBasicFunction:FC=(props)=>{const[state,setState]=useState<ItemType[]>([{id:1,name:"shrek"},{id:2,name:"fiona"},]);return(<ReactSortablelist={state}setList...
importReactfrom"react";import{ ReactSortable, Sortable, MultiDrag, Swap }from"react-sortablejs";// mount whatever plugins you'd like to. These are the only current options.Sortable.mount(newMultiDrag(),newSwap());constApp =()=>{const[state, setState] = useState([ {id:1,name:"shrek"}...
I'm using react-sortablejs 1.2.0 and sortablejs 1.5.0-rc1 and still having this issue. Also on a recent version of Chrome (v55). For now, I'm getting around this by marking the items as deleted, and then batching the deletes up into a deferred function. A style ofdisplay: noneis...
my-react-sortable module helps you create React sortable lists easily. Where you can re-arrange the list items.. Latest version: 1.1.4, last published: 4 years ago. Start using my-react-sortable in your project by running `npm i my-react-sortable`. There
https://www.npmjs.com/package/react-sortablejs Could you upload the latest version to npm? I really need it 😇 👍 7 joshreed commented Jul 27, 2023 Is there any chance you're planning to update this on NPM soon? It seems like it'd fix an issue I'm having. 👍 1 👀 2 ...
在实现这个的功能的过程中,也走了一点弯路,我们内部1.0版本的时候,使用的是sortablejs,由于代码写的比较混乱,拖拽功能经常出现卡死的现象,以为是sortablejs的问题,然后又换成大名鼎鼎的React Dnd,和Redux是同一个作者,但是Dnd并不是太符合我们的需求,拖拽的API确实很强大,但是排序、跨级拖拽等好多功能都要自己手动...
Describe the bug describe below information section To Reproduce Steps to reproduce the behavior: Go to 'page on list located(not first deps page) and refresh(window.location.reload() or click browser refresh button) ' Click on 'N/A' Scr...
$ npm install react-sortable-hoc --save Then, using a module bundler that supports either CommonJS or ES2015 modules, such aswebpack: // Using an ES6 transpiler like Babelimport{SortableContainer,SortableElement}from'react-sortable-hoc';// Not using an ES6 transpilervarSortable=require('react...
"react-sortablejs": "^6.1.4" "react": "^18.2.0" Additional context Using JSON.parse(JSON.stringify(...)) or a library like Lodash's _.cloneDeep can resolve the issue by ensuring that a deep copy of the list is created before any modifications are made. This way, the original list...