{"id":21152730,"url":"https://github.com/aodin/tablesorter","last_synced_at":"2026-01-27T15:33:21.513Z","repository":{"id":225600745,"uuid":"765365607","full_name":"aodin/tablesorter","owner":"aodin","description":"Native JS tablesorter","archived":false,"fork":false,"pushed_at":"2024-07-02T18:35:20.000Z","size":54,"stargazers_count":2,"open_issues_count":2,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-15T07:35:40.267Z","etag":null,"topics":[],"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/aodin.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}},"created_at":"2024-02-29T19:26:54.000Z","updated_at":"2025-08-20T10:29:07.000Z","dependencies_parsed_at":"2024-03-21T23:36:48.323Z","dependency_job_id":"fb160503-6e14-4943-a9b1-2c0dd395d74a","html_url":"https://github.com/aodin/tablesorter","commit_stats":null,"previous_names":["aodin/tablesorter"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/aodin/tablesorter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aodin%2Ftablesorter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aodin%2Ftablesorter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aodin%2Ftablesorter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aodin%2Ftablesorter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aodin","download_url":"https://codeload.github.com/aodin/tablesorter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aodin%2Ftablesorter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28815411,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-27T12:25:15.069Z","status":"ssl_error","status_checked_at":"2026-01-27T12:25:05.297Z","response_time":168,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":[],"created_at":"2024-11-20T10:46:09.542Z","updated_at":"2026-01-27T15:33:21.497Z","avatar_url":"https://github.com/aodin.png","language":"JavaScript","readme":"tablesorter\n===========\n\nNative JS tablesorter. [View a live example](https://aodin.github.io/tablesorter/).\n\n\nInstall with:\n\n```\nnpm i @aodin/tablesorter\n```\n\nA minified JS file and map is included in the `dist` directory along with optional CSS styles.\n\n\n### Usage\n\nTables must be initialized before sorting is active.\n\n```js\ntablesorter.New(document.getElementById(\"table\"))\n```\n\nOr to initialize all tables with a certain class, such as `tablesorter`:\n\n```js\ndocument.querySelectorAll(\".tablesorter\").forEach(elem =\u003e tablesorter.New(elem))\n```\n\nColumn types can be explicitly set using a `data-type` attribute on the `th` element. For example:\n\n```html\n\u003cth data-type=\"numeric\"\u003eData\u003c/th\u003e\n```\n\nTo prevent a column from being sortable, add a `no-sort` class to the `th` element.\n\nSorting can also be performed with the `sortAsc` and `sortDesc` methods:\n\n```js\nconst table = tablesorter.New(elem)\ntable.sortAsc(1)\ntable.sortDesc(1)\n```\n\n### Project summary\n\n* Native JS with no dependencies\n* About 1kb minified and compressed\n* Module and ES6 export based file structure\n* Simple class-based states: `active`, `asc`, `desc`\n* Reads from either the data attribute `data-value` or HTML inner text\n* Uses local string comparison\n* Default sort for text columns is ascending, default sort for numeric is descending\n* Table fires a `sort` event when sorted, which includes col and asc details\n* Includes example Sass and CSS styles\n* MIT license\n\n\n### Development\n\nTest with:\n\n```\nnpm test\n```\n\nBuild with:\n\n```\nnpm run build\n```\n\nHappy hacking!\n\naodin, 2024\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faodin%2Ftablesorter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faodin%2Ftablesorter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faodin%2Ftablesorter/lists"}