{"id":15239086,"url":"https://github.com/babiabeo/tiny-math","last_synced_at":"2026-02-16T22:02:05.601Z","repository":{"id":155813474,"uuid":"628646849","full_name":"babiabeo/tiny-math","owner":"babiabeo","description":"A tiny package for simple math utils","archived":false,"fork":false,"pushed_at":"2024-03-24T14:11:42.000Z","size":31,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-11-09T22:59:37.540Z","etag":null,"topics":["bun","deno","math","module","nodejs","web"],"latest_commit_sha":null,"homepage":"https://jsr.io/@babia/tiny-math","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/babiabeo.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}},"created_at":"2023-04-16T15:45:38.000Z","updated_at":"2024-03-24T14:06:13.000Z","dependencies_parsed_at":"2024-03-24T15:24:02.954Z","dependency_job_id":"923bf5d1-a284-4ec6-9111-cc9e01827776","html_url":"https://github.com/babiabeo/tiny-math","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/babiabeo/tiny-math","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/babiabeo%2Ftiny-math","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/babiabeo%2Ftiny-math/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/babiabeo%2Ftiny-math/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/babiabeo%2Ftiny-math/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/babiabeo","download_url":"https://codeload.github.com/babiabeo/tiny-math/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/babiabeo%2Ftiny-math/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29521106,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-16T21:45:09.491Z","status":"ssl_error","status_checked_at":"2026-02-16T21:44:58.452Z","response_time":115,"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":["bun","deno","math","module","nodejs","web"],"created_at":"2024-09-29T10:05:13.000Z","updated_at":"2026-02-16T22:02:05.582Z","avatar_url":"https://github.com/babiabeo.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tiny-math\n\nA tiny, easy-to-use, zero-dependency package providing some math utils.\n\n## Usage\n\nThis package is available on [jsr.io](https://jsr.io) and compatible with any browsers and JavaScript runtimes.\n\nTo install:\n\n```sh\n# Deno\ndeno add @babia/tiny-math\n\n# npm\nnpx jsr add @babia/tiny-math\n\n# yarn\nyarn dlx jsr add @babia/tiny-math\n\n# pnpm\npnpm dlx jsr add @babia/tiny-math\n\n# Bun\nbunx jsr add @babia/tiny-math\n```\n\nFor Deno user, this package is also available on [deno.land/x](https://deno.land/x)\n\n```ts\nimport * as math from \"https://deno.land/x/tiny_math@$VERSION/mod.ts\";\n```\n\nRemember to use imports with pinned version to avoid unintended changes.\n\n## Examples\n\nBelow are some examples of `factorial`, `gcd` and `lcm`. For more, see [examples](./examples/).\n\n### `factorial`\n\n```ts\nimport { factorial } from \"@babia/tiny-math\";\n\nconsole.log(factorial(0));     // 0! = 1\nconsole.log(factorial(7));     // 7! = 5040\nconsole.log(factorial(15));    // 15! = 1307674368000\nconsole.log(factorial(20));    // 20! = 2432902008176640000\n```\n\n### `gcd` and `lcm`\n\n```ts\nimport { gcd, lcm } from \"@babia/tiny-math\";\n\nconsole.log(gcd(27, 60));       // 3\nconsole.log(gcd(24, 32, 21));   // 1\nconsole.log(lcm(50, 90));       // 450\nconsole.log(lcm(55, 30, 23));   // 7590\n```\n\n## Documentation\n\nPlease go to [this page](https://jsr.io/@babia/tiny-math/doc) and navigate to any function you want to see.\n\n## License\n\nThis package is under [MIT License](./LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbabiabeo%2Ftiny-math","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbabiabeo%2Ftiny-math","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbabiabeo%2Ftiny-math/lists"}