{"id":16364832,"url":"https://github.com/djhi/meteor-formatting","last_synced_at":"2026-02-11T17:30:17.987Z","repository":{"id":18209784,"uuid":"21344550","full_name":"djhi/meteor-formatting","owner":"djhi","description":"Provides helpers for quick formatting of dates and numbers. Integration of moment (with languages) and numeral (with languages too).","archived":false,"fork":false,"pushed_at":"2014-07-10T18:28:13.000Z","size":192,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-30T21:43:54.143Z","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/djhi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-06-30T08:32:18.000Z","updated_at":"2024-04-27T16:07:40.000Z","dependencies_parsed_at":"2022-09-04T16:12:01.679Z","dependency_job_id":null,"html_url":"https://github.com/djhi/meteor-formatting","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/djhi%2Fmeteor-formatting","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djhi%2Fmeteor-formatting/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djhi%2Fmeteor-formatting/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/djhi%2Fmeteor-formatting/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/djhi","download_url":"https://codeload.github.com/djhi/meteor-formatting/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239808523,"owners_count":19700452,"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":[],"created_at":"2024-10-11T02:32:20.829Z","updated_at":"2026-02-11T17:30:17.908Z","avatar_url":"https://github.com/djhi.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"meteor-formatting\n=================\n\nProvides helpers for quick formatting of dates and numbers. Integration of moment (with languages) and numeral (with languages too).\n\n# Dates Helpers\n\n## duration\nOuput the result of `moment().duration`. \n\n**parameters**\n\n *\t`duration`: the duration (example: `10`)\n *\t`units`: units used for the duration (default is `hours`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{duration 10 'days'}}\u003c/span\u003e\n```\n\n## fromNow\nOuput the result of `moment.fromNow`. \n\n**parameters**\n\n *\t`date`: the date (example: `01/01/2014`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{fromNow myDate}}\u003c/span\u003e\n```\n\n## formatDate\nOuput the result of `moment.format`. \n\n**parameters**\n\n *\t`date`: the date (example: `01/01/2014`)\n *\t`format`: format used (default is `DD/MM/YYYY`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{formatDate myDate}}\u003c/span\u003e\n```\n\n## mediumDate\nOuput the result of `moment.format('LL')`. \n\n**parameters**\n\n *\t`date`: the date (example: `01/01/2014`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{mediumDate myDate}}\u003c/span\u003e\n```\n\n## month\nOuput the result of `moment.format('MMMM')` (Ouput the full month's name)\n\n**parameters**\n\n *\t`date`: the date (example: `01/01/2014`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{month myDate}}\u003c/span\u003e\n```\n\n## shortMonthAndYear\nOuput the result of `moment.format('MM YYYY')` (Ouput the short month's name and the year)\n\n**parameters**\n\n *\t`date`: the date (example: `01/01/2014`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{shortMonthAndYear myDate}}\u003c/span\u003e\n```\n# Numbers Helpers\n\n## currency\nOuput the result of `numeral().format('$0.00')` or `numeral().format('0.00$')`. \n\n**parameters**\n\n *\t`number`: the number to format (example: `10`)\n *\t`symbolAtEnd`: wether to show the currency symbol at the end (default is `false`)\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{currency 10}}\u003c/span\u003e\n```\n``` handlebars\n\u003cspan\u003e{{currency 10 true}}\u003c/span\u003e\n```\n\n## percentage\nOuput the result of `numeral().format('0%')`. \n\n**parameters**\n\n *\t`number`: the number to format (example: `10`). If this number is greater than 1, it will be divided by 100 as numeral expect a number lesser than 1.\n\n**usage**\n``` handlebars\n\u003cspan\u003e{{percentage 10}}\u003c/span\u003e\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdjhi%2Fmeteor-formatting","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdjhi%2Fmeteor-formatting","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdjhi%2Fmeteor-formatting/lists"}