{"id":29835157,"url":"https://github.com/myobie/choo-drag-and-drop-sortable-tree-example","last_synced_at":"2026-06-24T21:31:09.996Z","repository":{"id":66433866,"uuid":"138338811","full_name":"myobie/choo-drag-and-drop-sortable-tree-example","owner":"myobie","description":"An example of using choo and html5 drag and drop sortable tree","archived":false,"fork":false,"pushed_at":"2018-07-16T10:12:50.000Z","size":102,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-03-01T22:43:42.851Z","etag":null,"topics":["choo","drag-and-drop","html5","javascript"],"latest_commit_sha":null,"homepage":"","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/myobie.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2018-06-22T19:03:36.000Z","updated_at":"2018-07-16T10:12:51.000Z","dependencies_parsed_at":null,"dependency_job_id":"94151860-acfd-4267-a0e7-343f7df5ff9e","html_url":"https://github.com/myobie/choo-drag-and-drop-sortable-tree-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/myobie/choo-drag-and-drop-sortable-tree-example","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/myobie%2Fchoo-drag-and-drop-sortable-tree-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/myobie%2Fchoo-drag-and-drop-sortable-tree-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/myobie%2Fchoo-drag-and-drop-sortable-tree-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/myobie%2Fchoo-drag-and-drop-sortable-tree-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/myobie","download_url":"https://codeload.github.com/myobie/choo-drag-and-drop-sortable-tree-example/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/myobie%2Fchoo-drag-and-drop-sortable-tree-example/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34750952,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-24T02:00:07.484Z","response_time":106,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["choo","drag-and-drop","html5","javascript"],"created_at":"2025-07-29T12:17:07.576Z","updated_at":"2026-06-24T21:31:09.992Z","avatar_url":"https://github.com/myobie.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Drag \u0026 Drop Sortable Tree\n=========================\n\nThis is an example of using a redux-like system ([choo](https://choo.io/)) with\nHTML5's drag and drop APIs.\n\nThere are actually three layers in this example to make the three functions\neasier and seperate:\n\n1. Ghost layer\n2. Draggable layer\n3. Droppable layer\n\nThe droppables are only shown if a drag is in process. The ghosts are only\nthere so we can animate items moving up and down as one drags around. The\ndroppables are seperate so it's easier to show a line to indicate whether a\ndrop will land inside a group or outside the group.\n\nIt's not necessary to have all three and I really should clean it up to have\nonly one list in the end and just include the ghost and the droppable markers\nall inside the draggable list items.\n\n## TODO\n\n* The logic for detecting where the user intends to drop an item is way too\n  complicated.\n* The patch for a drop is also complicated, but it doesn't bother me as much.\n* There are too many functions that rely on `state` being in scope.\n* Don't have three layers\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmyobie%2Fchoo-drag-and-drop-sortable-tree-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmyobie%2Fchoo-drag-and-drop-sortable-tree-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmyobie%2Fchoo-drag-and-drop-sortable-tree-example/lists"}