{"id":13447740,"url":"https://github.com/davidfig/sortable","last_synced_at":"2025-04-14T23:44:16.332Z","repository":{"id":57404903,"uuid":"128862785","full_name":"davidfig/sortable","owner":"davidfig","description":"Vanilla drag-and-drop sortable list(s)","archived":false,"fork":false,"pushed_at":"2019-02-21T02:38:49.000Z","size":24250,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-14T23:44:05.291Z","etag":null,"topics":["drag","drop","lists","order","sort","vanilla"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/davidfig.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-10T02:37:05.000Z","updated_at":"2021-06-18T15:01:49.000Z","dependencies_parsed_at":"2022-09-03T19:30:54.237Z","dependency_job_id":null,"html_url":"https://github.com/davidfig/sortable","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidfig%2Fsortable","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidfig%2Fsortable/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidfig%2Fsortable/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidfig%2Fsortable/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/davidfig","download_url":"https://codeload.github.com/davidfig/sortable/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248981259,"owners_count":21193143,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["drag","drop","lists","order","sort","vanilla"],"created_at":"2024-07-31T05:01:25.690Z","updated_at":"2025-04-14T23:44:16.312Z","avatar_url":"https://github.com/davidfig.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# yy-sortable\r\nVanilla drag-and-drop sortable list(s)\r\n\r\nFeatures include:\r\n\r\n* dragging and dropping between sortable and/or ordered lists (options.sort)\r\n* three ways to handle dragging off lists:\r\n  1. closest - find closest list\r\n  2. cancel - return to original position before dragging\r\n  3. delete - remove element from all lists\r\n* lists that are copy-only or no-drop (options.copy and options.drop) \r\n* custom ghost image and icon support so dragging looks nicer and isn't limited by browser\r\n* search descendents for a className when determining where to sort or how to order (options.deepSearch)\r\n* limit the number of elements in a sortable (options.maximum)\r\n* robust event system based on eventemitter3 (i.e., add, remove, order, update, delete, and -pending versions of these events)\r\n* ordered lists may be reverse ordered and ordered by a data-? setting\r\n* dynamically add elements\r\n* uses built in drag and drop API\r\n\r\n## Rationale\r\nI tried many of the existing drag-and-drop libraries but could not find all the features I wanted in one neat package.\r\n\r\n## Super Simple Example\r\n```js\r\nnew Sortable(document.getElementById('sortme'))\r\n```\r\n\r\n## Examples Showing Features\r\n[davidfig.github.io/sortable/](https://davidfig.github.io/sortable/)\r\n\r\n## API Documentation\r\n[davidfig.github.io/sortable/jsdoc/](https://davidfig.github.io/sortable/jsdoc/)\r\n\r\n## Installation\r\n\r\n    npm i yy-sortable\r\n\r\n## Influences\r\nI was greatly influenced by the design of [sortablejs](https://github.com/RubaXa/Sortable), which was *almost* perfect.\r\n\r\n## license  \r\nMIT License  \r\n(c) 2018 [YOPEY YOPEY LLC](https://yopeyopey.com/) by [David Figatner](https://twitter.com/yopey_yopey/)\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidfig%2Fsortable","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdavidfig%2Fsortable","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidfig%2Fsortable/lists"}