{"id":15436208,"url":"https://github.com/scurker/thousands","last_synced_at":"2025-04-19T18:49:05.720Z","repository":{"id":65412387,"uuid":"79193005","full_name":"scurker/thousands","owner":"scurker","description":"A micro js library for formatting numbers with thousands separator","archived":false,"fork":false,"pushed_at":"2017-01-17T06:13:37.000Z","size":5,"stargazers_count":13,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-29T11:51:43.278Z","etag":null,"topics":["formatting","javascript","micro-library","numbers"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/scurker.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}},"created_at":"2017-01-17T05:43:29.000Z","updated_at":"2022-11-11T05:09:38.000Z","dependencies_parsed_at":"2023-01-22T07:55:24.810Z","dependency_job_id":null,"html_url":"https://github.com/scurker/thousands","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scurker%2Fthousands","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scurker%2Fthousands/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scurker%2Fthousands/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scurker%2Fthousands/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/scurker","download_url":"https://codeload.github.com/scurker/thousands/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249173060,"owners_count":21224481,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["formatting","javascript","micro-library","numbers"],"created_at":"2024-10-01T18:49:13.757Z","updated_at":"2025-04-16T12:30:51.392Z","avatar_url":"https://github.com/scurker.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# thousands [![Build Status](https://travis-ci.org/scurker/thousands.svg?branch=master)](https://travis-ci.org/scurker/thousands) [![npm](https://img.shields.io/npm/v/thousands.svg?style=flat)](https://www.npmjs.com/package/thousands)\n\nA micro javascript library for formatting numbers with thousands separator.\n\n#### Why should I use this over [Number.toLocaleString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/toLocaleString)?\n\n`Number.toLocaleString()` isn't supported in some browsers (\u003c Safari 9, \u003c IE 11), or if you're running in an older node environment (\u003c 0.12) i18n support is not included. In most cases you will likely want to use `Number.toLocaleString()`, but this library allows you to format numbers no matter what your environment supports.\n\n## Install\n\n```\n$ npm install --save thousands\n```\n\n## Usage\n\n```js\nconst thousands = require('thousands');\n\nthousands(1234);      // =\u003e 1,234\nthousands(123456);    // =\u003e 123,456\nthousands('1234.56'); // =\u003e 1,234.56\n\nthousands(1234, ' ');      // =\u003e 1 234\nthousands(123456, ' ');    // =\u003e 123 456\nthousands('1234.56', ' '); // =\u003e 1 234.56\n\n```\n\n## License\n\nMIT © [Jason Wilson](http://scurker.com)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscurker%2Fthousands","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscurker%2Fthousands","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscurker%2Fthousands/lists"}