{"id":13780037,"url":"https://github.com/koajs/timer","last_synced_at":"2025-10-19T13:31:33.372Z","repository":{"id":47110540,"uuid":"44301564","full_name":"koajs/timer","owner":"koajs","description":"time your middleware","archived":false,"fork":false,"pushed_at":"2021-09-13T05:17:15.000Z","size":6,"stargazers_count":27,"open_issues_count":2,"forks_count":4,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-10-29T15:32:13.551Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/koajs.png","metadata":{"files":{"readme":"Readme.md","changelog":"History.md","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":"2015-10-15T07:43:33.000Z","updated_at":"2024-07-19T23:57:34.000Z","dependencies_parsed_at":"2022-09-04T08:40:13.855Z","dependency_job_id":null,"html_url":"https://github.com/koajs/timer","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/koajs%2Ftimer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koajs%2Ftimer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koajs%2Ftimer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/koajs%2Ftimer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/koajs","download_url":"https://codeload.github.com/koajs/timer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237133590,"owners_count":19260506,"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-08-03T18:01:11.712Z","updated_at":"2025-10-19T13:31:28.060Z","avatar_url":"https://github.com/koajs.png","language":"JavaScript","funding_links":[],"categories":["Middleware"],"sub_categories":[],"readme":"\n# koa-timer\n\n  time your middleware\n\n  ![img](https://cldup.com/E2OA3LEane.png)\n\n## Install\n\n```\nnpm install koa-timer\n```\n\n## Example\n\nSee the [example](examples/index.js).\n\n## API\n\n#### `timer = Timer(options)`\n\nInitialize a timer with the following options:\n\n- slow (default 75): set what \"slow\" middleware means to your app\n- debug (default \"koa:timer\"): the debug namespace you want to use\n- threshold (default: false): only display middleware that's slower than the threshold\n- verbose (default: false): setting to true will show the timing before and after `yield next`\n\nThen to instrument the middleware, you do the following:\n\n```js\napp.use(timer(middleware()))\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkoajs%2Ftimer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkoajs%2Ftimer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkoajs%2Ftimer/lists"}