{"id":19028499,"url":"https://github.com/angelozdev/chrono-convert","last_synced_at":"2026-02-15T21:33:57.793Z","repository":{"id":204989555,"uuid":"713137417","full_name":"angelozdev/chrono-convert","owner":"angelozdev","description":"Effortlessly manipulate and convert time units with Chrono-Convert, the JavaScript library offering a fluent, chainable interface for clear and precise time calculations. Perfect for adding sophisticated time-based logic to your applications with ease and elegance.","archived":false,"fork":false,"pushed_at":"2025-03-25T22:40:26.000Z","size":39,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-09T03:15:09.602Z","etag":null,"topics":[],"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/angelozdev.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":"2023-11-01T23:10:06.000Z","updated_at":"2025-03-25T22:40:31.000Z","dependencies_parsed_at":null,"dependency_job_id":"7f9c1df2-3404-4084-a56b-0d3d94d5669e","html_url":"https://github.com/angelozdev/chrono-convert","commit_stats":null,"previous_names":["angelozdev/chrono-convert"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/angelozdev/chrono-convert","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angelozdev%2Fchrono-convert","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angelozdev%2Fchrono-convert/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angelozdev%2Fchrono-convert/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angelozdev%2Fchrono-convert/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/angelozdev","download_url":"https://codeload.github.com/angelozdev/chrono-convert/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angelozdev%2Fchrono-convert/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29490352,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-15T19:29:10.908Z","status":"ssl_error","status_checked_at":"2026-02-15T19:29:10.419Z","response_time":118,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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-08T21:11:15.837Z","updated_at":"2026-02-15T21:33:57.779Z","avatar_url":"https://github.com/angelozdev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Chrono Convert\n\nEffortlessly manipulate and convert time units with Chrono-Convert, the JavaScript library offering a fluent, chainable interface for clear and precise time calculations. Perfect for adding sophisticated time-based logic to your applications with ease and elegance.\n\n## Features\n\n- **Fluent Interface**: Easy-to-read, chainable methods.\n- **Versatile**: Convert between seconds, minutes, hours, and more.\n- **Lightweight**: Minimally impacts your project's footprint.\n- **No Dependencies**: Use it out of the box without worrying about additional packages.\n\n## Installation\n\nInstall `chrono-convert` using your preferred package manager.\n\n```bash\n# With npm\nnpm install chrono-convert\n\n# With yarn\nyarn add chrono-convert\n\n# With pnpm\npnpm add chrono-convert\n```\n\n## Usage\n\nThe `chrono-convert` library provides a fluent interface for manipulating and converting time units. This makes it easy to perform sophisticated time-based calculations in your JavaScript projects.\n\n### Getting Started\n\nFirst, you need to import `chrono-convert` into your project.\n\nFor CommonJS:\n\n```javascript\nconst chrono = require(\"chrono-convert\");\n```\n\nFor ES6 modules:\n\n```javascript\nimport chrono from \"chrono-convert\";\n```\n\n### Converting Time\n\n```javascript\nconst time = chrono.minutes(5).add(50, \"minutes\").toSeconds();\nconst time = chrono.from(5, \"minutes\").add(50, \"minutes\").to(\"seconds\");\nconsole.log(time); // 3300\n\nconst time = chrono.hours(2).add(30, \"minutes\").toMinutes();\nconst time = chrono.from(2, \"hours\").add(30, \"minutes\").to(\"minutes\");\nconsole.log(time); // 150\n\nconst time = chrono.seconds(120).subtract(30, \"seconds\").toMinutes();\nconst time = chrono.from(120, \"seconds\").subtract(30, \"seconds\").to(\"minutes\");\nconsole.log(time); // 1.5\n\nconst time = chrono.seconds(120).subtract(30, \"seconds\").toHours();\nconst time = chrono.from(120, \"seconds\").subtract(30, \"seconds\").to(\"hours\");\nconsole.log(time); // 0.025\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangelozdev%2Fchrono-convert","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fangelozdev%2Fchrono-convert","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangelozdev%2Fchrono-convert/lists"}