{"id":18715431,"url":"https://github.com/rawnly/easy-registry","last_synced_at":"2026-05-10T19:02:53.984Z","repository":{"id":57218656,"uuid":"81855986","full_name":"rawnly/easy-registry","owner":"rawnly","description":"Easy NPM Registry API module ","archived":false,"fork":false,"pushed_at":"2017-03-17T20:39:20.000Z","size":54,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-12-28T09:43:23.551Z","etag":null,"topics":["javascript","node","nodejs","npm","registry"],"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/rawnly.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":"2017-02-13T18:17:51.000Z","updated_at":"2020-01-15T21:18:19.000Z","dependencies_parsed_at":"2022-08-28T23:22:12.985Z","dependency_job_id":null,"html_url":"https://github.com/rawnly/easy-registry","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rawnly%2Feasy-registry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rawnly%2Feasy-registry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rawnly%2Feasy-registry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rawnly%2Feasy-registry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rawnly","download_url":"https://codeload.github.com/rawnly/easy-registry/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239577543,"owners_count":19662247,"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":["javascript","node","nodejs","npm","registry"],"created_at":"2024-11-07T13:08:43.030Z","updated_at":"2025-11-10T05:30:21.567Z","avatar_url":"https://github.com/rawnly.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Easy Registry\n\n\u003cp align=\"center\"\u003e \u003cimg src=\"https://cloud.githubusercontent.com/assets/16429579/22896657/3f5b2b66-f221-11e6-8702-3c51f80896f5.png\" alt=\"wall\"\u003e\u003c/p\u003e\n\n\u003e Easy tool for [NPM Registry][registry]\n\nThis module provides to give you information about a **npm** module.\n\nYou can grab downloads and `date` informations. You can also use [this module](https://github.com/jstrace/chart) to create beautiful chars.\n\n\n## Install\n**NPM**\n```bash\n  $ npm install easy-registry --save\n```\n\n**YARN**\n```bash\n  $ yarn add easy-registry\n```\n\n## Usage\n```js\n// Modules\nconst chart = require('chart');\nconst chili = require('chili-js');\nconst Package = require('easy-registry')\n\n// Variables\nconst myModule = new Package('myModule')\n\n// The magic happens\nmyModule.day((err, infos) =\u003e {\n  let downloads = infos.map(info =\u003e {\n    return info.downloads\n  });\n\n  downloads.sort((a, b) =\u003e {\n    return a - b\n  });\n\n  const ch = chart(downloads, {\n    width: 70,\n    height: 30\n  });\n\n  console.log(ch);\n});\n```\n\u003e With Callback\n\n\u003cbr\u003e\n\u003cbr\u003e\n\u003cbr\u003e\n\n```javascript\n// Modules\nconst chart = require('chart');\nconst chili = require('chili-js');\nconst Package = require('easy-registry')\n\n// Variables\nconst myModule = new Package('myModule')\n\n// The magic happens\nmyModule.day().then(infos =\u003e {\n  const downloads = infos.map(info =\u003e {\n    return info.downloads\n  });\n\n  // .sum() is a `chili-js` function!\n  console.log(`Total: ${downloads.sum()}`);\n\n}).catch(err =\u003e {\n  throw new Error(err)\n})\n```\n\u003e With Promises\n\nView the [full example](samples/example.js) for more informations about `data manipulation`.\n\n\u003cbr\u003e\n\n## API\n1. `.day(callback)`   - Get datas about the last day.\n2. `.week(callback)`  - Get datas about the last week.\n3. `.month(callback)` - Get datas about the last month.\n4. `.year(callback)`  - Get datas about the last year.\n5. `.total(callback)` - Get datas from `1 Jan 1000` to the `current day`.\n\n## Modules in the examples\n- [chili-js](https://github.com/rawnly/chili-js) - Useful NodeJs variables and functions\n- [jstrace/chart](https://github.com/jstrace/chart) - Ansi charts for nodejs\n\n\n\n---\n\u003e Made with :heart: by [@Rawnly](https://github.com/rawnly)\n\n\n[registry]: https://registry.npmjs.org\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frawnly%2Feasy-registry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frawnly%2Feasy-registry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frawnly%2Feasy-registry/lists"}