{"id":16231581,"url":"https://github.com/hustcc/byte-parser","last_synced_at":"2026-03-07T16:03:19.211Z","repository":{"id":66093467,"uuid":"295727933","full_name":"hustcc/byte-parser","owner":"hustcc","description":":eight: (130B) Parse byte string to byte number, e.g. 1.2 Kb -\u003e 1228.8, Kb, Mb, Gb, Tb, Pb, Eb, Zb, Yb supported.","archived":false,"fork":false,"pushed_at":"2020-09-15T12:55:20.000Z","size":3,"stargazers_count":7,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-03T03:32:49.117Z","etag":null,"topics":["byte","byte-number","byte-parser"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/hustcc.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":"2020-09-15T12:54:56.000Z","updated_at":"2020-11-22T16:06:12.000Z","dependencies_parsed_at":"2023-03-10T23:36:53.895Z","dependency_job_id":null,"html_url":"https://github.com/hustcc/byte-parser","commit_stats":{"total_commits":1,"total_committers":1,"mean_commits":1.0,"dds":0.0,"last_synced_commit":"fc143e70513aa9b034ae798832a1980e373e8e05"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hustcc/byte-parser","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hustcc%2Fbyte-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hustcc%2Fbyte-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hustcc%2Fbyte-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hustcc%2Fbyte-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hustcc","download_url":"https://codeload.github.com/hustcc/byte-parser/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hustcc%2Fbyte-parser/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30221193,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T14:02:48.375Z","status":"ssl_error","status_checked_at":"2026-03-07T14:02:43.192Z","response_time":53,"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":["byte","byte-number","byte-parser"],"created_at":"2024-10-10T13:06:09.855Z","updated_at":"2026-03-07T16:03:19.193Z","avatar_url":"https://github.com/hustcc.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# byte-parser\n\n\u003e Parse byte string to byte number, e.g. `1.2 Kb` -\u003e `1228.8`, Kb, Mb, Gb, Tb, Pb, Eb, Zb, Yb supported.\n\n[![npm Version](https://img.shields.io/npm/v/byte-parser.svg)](https://www.npmjs.com/package/byte-parser)\n[![Build Status](https://github.com/hustcc/byte-parser/workflows/build/badge.svg)](https://github.com/hustcc/byte-parser/actions)\n[![npm](https://img.shields.io/npm/dm/byte-parser.svg)](https://www.npmjs.com/package/byte-parser)\n[![npm License](https://img.shields.io/npm/l/byte-parser.svg)](https://www.npmjs.com/package/byte-parser)\n\n\n## Install\n\n```bash\n$ npm i --save-dev byte-parser\n```\n\n\n## Usage\n\n```ts\nimport parse from 'byte-parser';\n\nparse('100');               // 100\nparse('10.1 b');            // 10.1\nparse('10.1 KB');           // 10.1 * 1024\nparse('10.1 kb', 1000);     // 10.1 * 1000\nparse('1.2 mb');            // 1.2 * 1024 * 1024\nparse('1.2 Gb');            // 1.2 * 1024 * 1024 * 1024\nparse('1.2 G');             // 1.2 * 1024 * 1024 * 1024\n```\n\n\n## License\n\nMIT@[hustcc](https://github.com/hustcc).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhustcc%2Fbyte-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhustcc%2Fbyte-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhustcc%2Fbyte-parser/lists"}