{"id":19910975,"url":"https://github.com/streetsidesoftware/perf-insight","last_synced_at":"2026-02-27T22:10:03.654Z","repository":{"id":234955614,"uuid":"789763838","full_name":"streetsidesoftware/perf-insight","owner":"streetsidesoftware","description":"Performance Benchmarking Tool","archived":false,"fork":false,"pushed_at":"2026-02-25T12:13:29.000Z","size":1152,"stargazers_count":0,"open_issues_count":8,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-02-25T16:18:39.218Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/streetsidesoftware.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"streetsidesoftware","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":null,"custom":null}},"created_at":"2024-04-21T13:50:57.000Z","updated_at":"2026-02-12T17:28:50.000Z","dependencies_parsed_at":"2024-04-21T20:39:16.505Z","dependency_job_id":"c127e363-00d1-4f41-84c9-45ebea7c9e9c","html_url":"https://github.com/streetsidesoftware/perf-insight","commit_stats":null,"previous_names":["streetsidesoftware/perf-bench","streetsidesoftware/perf-insight"],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/streetsidesoftware/perf-insight","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streetsidesoftware%2Fperf-insight","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streetsidesoftware%2Fperf-insight/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streetsidesoftware%2Fperf-insight/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streetsidesoftware%2Fperf-insight/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/streetsidesoftware","download_url":"https://codeload.github.com/streetsidesoftware/perf-insight/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/streetsidesoftware%2Fperf-insight/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29917212,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-27T19:37:42.220Z","status":"ssl_error","status_checked_at":"2026-02-27T19:37:41.463Z","response_time":57,"last_error":"SSL_read: 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-12T21:22:43.408Z","updated_at":"2026-02-27T22:10:03.645Z","avatar_url":"https://github.com/streetsidesoftware.png","language":"TypeScript","funding_links":["https://github.com/sponsors/streetsidesoftware"],"categories":[],"sub_categories":[],"readme":"# Performance Insight\n\nPerformance Benchmarking Suite for NodeJS.\n\n## Install\n\n1. `npm i -D perf-insight`\n\n## Getting Started.\n\n## CLI Help\n\n**`npx perf-insight --help`**\n\n\u003c!--- @@inject: static/help.txt ---\u003e\n\n```\nUsage: perf-insight [options] [filter...]\n\nBenchmark performance suites found in `**/*.perf.{js,cjs,mjs}`.\n\nArguments:\n  filter                   Perf file filter.\n\nOptions:\n  -a, --all                Run all perf files. (default: false)\n  -f, --file \u003cglob...\u003e     Globs to search for perf files.\n  -x, --exclude \u003cglob...\u003e  Globs to exclude from search.\n  -t, --timeout \u003ctimeout\u003e  Override the timeout for each test suite.\n  -s, --suite \u003csuite...\u003e   Run only matching suites.\n  -T, --test \u003ctest...\u003e     Run only matching test found in suites\n  --fail-fast              Stop on first failure. (default: false)\n  --repeat \u003ccount\u003e         Repeat the tests. (default: 1)\n  --register \u003cloader\u003e      Register a module loader. (e.g. jiti/register)\n  -h, --help               display help for command\n```\n\n\u003c!--- @@inject-end: static/help.txt ---\u003e\n\n## Running Benchmarks\n\n**Example `example.perf.mjs` file**\n\n\u003c!--- @@inject: examples/dist/exampleMap.perf.mjs ---\u003e\n\n```javascript\nimport { loremIpsum } from 'lorem-ipsum';\nimport { suite } from 'perf-insight';\n// Use 2 seconds as the default timeout for tests in the suite.\n// The `--timeout` option can override this value.\nconst defaultTimeout = 2000;\n// ts-check\nsuite('map', 'Measure .map performance with different functions', async (test) =\u003e {\n  let knownWords = [];\n  test.beforeAll(() =\u003e {\n    knownWords = loremIpsum({ count: 10000, units: 'words' }).split(' ');\n  });\n  test('map((a) =\u003e !!a)', () =\u003e {\n    return knownWords.map((a) =\u003e !!a);\n  });\n  test('map((a) =\u003e a != \"\")', () =\u003e {\n    return knownWords.map((a) =\u003e a != '');\n  });\n  test('map((a) =\u003e a.length)', () =\u003e {\n    return knownWords.map((a) =\u003e a.length);\n  });\n  test('map((a) =\u003e !!a.length)', () =\u003e {\n    return knownWords.map((a) =\u003e !!a.length);\n  });\n  test('.map((a) =\u003e { return a.length; })', () =\u003e {\n    return knownWords.map((a) =\u003e {\n      return a.length;\n    });\n  });\n  test('.map(Boolean)', () =\u003e {\n    return knownWords.map(Boolean);\n  });\n  test('.map((a) =\u003e !a.length)', () =\u003e {\n    return knownWords.map((a) =\u003e !a.length);\n  });\n  test('.map((a) =\u003e { return !a.length; })', () =\u003e {\n    return knownWords.map((a) =\u003e {\n      return !a.length;\n    });\n  });\n  function len(a) {\n    return a.length;\n  }\n  function hasLen(a) {\n    return !!a.length;\n  }\n  test('.map(function len)', () =\u003e {\n    return knownWords.map(len);\n  });\n  test('.map(function hasLen)', () =\u003e {\n    return knownWords.map(hasLen);\n  });\n}).setTimeout(defaultTimeout); // set the default timeout for this suite.\n```\n\n\u003c!--- @@inject-end: examples/dist/exampleMap.perf.mjs ---\u003e\n\n**Example Output:**\n\n**`npx perf-insight exampleMap.perf.mjs --timeout 500`**\n\n\u003c!--- @@inject: static/example.txt ---\u003e\n\n```\nFile: examples/dist/exampleMap.perf.mjs\nRunning Perf Suite: map\nMeasure .map performance with different functions\n✔ map((a) =\u003e !!a)                    17922.63 ops/sec   8910 iterations  497.14ms time\n✔ map((a) =\u003e a != \"\")                17113.94 ops/sec   8521 iterations  497.90ms time\n✔ map((a) =\u003e a.length)               19090.99 ops/sec   9502 iterations  497.72ms time\n✔ map((a) =\u003e !!a.length)             18338.71 ops/sec   9133 iterations  498.02ms time\n✔ .map((a) =\u003e { return a.length; })  19056.21 ops/sec   9489 iterations  497.95ms time\n✔ .map(Boolean)                      18051.54 ops/sec   8991 iterations  498.07ms time\n✔ .map((a) =\u003e !a.length)             18182.27 ops/sec   9056 iterations  498.07ms time\n✔ .map((a) =\u003e { return !a.length; }) 17654.60 ops/sec   8794 iterations  498.11ms time\n✔ .map(function len)                 19423.79 ops/sec   9672 iterations  497.95ms time\n✔ .map(function hasLen)              18287.86 ops/sec   9109 iterations  498.09ms time\ndone.\n```\n\n\u003c!--- @@inject-end: static/example.txt ---\u003e\n\n## TypeScript Support\n\nIt is necessary to register a TypeScript loader like [jiti](https://github.com/unjs/jiti).\n\n**Usage:**\n\n```\nnpx perf-insight --file \"**/*.perf.mts\" --timeout 500 --register jiti/register\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstreetsidesoftware%2Fperf-insight","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstreetsidesoftware%2Fperf-insight","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstreetsidesoftware%2Fperf-insight/lists"}