{"id":16325315,"url":"https://github.com/poolifier/tatami-ng","last_synced_at":"2025-03-16T14:31:06.074Z","repository":{"id":231895273,"uuid":"782978605","full_name":"poolifier/tatami-ng","owner":"poolifier","description":"Cross JavaScript runtime benchmarking library and CLI","archived":false,"fork":false,"pushed_at":"2025-03-10T11:17:51.000Z","size":1946,"stargazers_count":7,"open_issues_count":7,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-10T14:44:52.763Z","etag":null,"topics":["benchmark","browser","bun","deno","javascript","node"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"evanwashere/mitata","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/poolifier.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},"funding":{"patreon":"fraggle_","github":"jerome-benoit","buy_me_a_coffee":"jbenoit100n"}},"created_at":"2024-04-06T15:38:49.000Z","updated_at":"2025-03-10T11:17:54.000Z","dependencies_parsed_at":"2024-08-21T11:36:13.078Z","dependency_job_id":"91eefe42-3a8c-4ee5-ad39-36d9dc1e38f1","html_url":"https://github.com/poolifier/tatami-ng","commit_stats":{"total_commits":408,"total_committers":9,"mean_commits":"45.333333333333336","dds":"0.11274509803921573","last_synced_commit":"cf235d347217e218e5dc4a6999452b987747790b"},"previous_names":["poolifier/mitata","poolifier/tatami","poolifier/tatami-ng"],"tags_count":63,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/poolifier%2Ftatami-ng","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/poolifier%2Ftatami-ng/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/poolifier%2Ftatami-ng/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/poolifier%2Ftatami-ng/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/poolifier","download_url":"https://codeload.github.com/poolifier/tatami-ng/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243818195,"owners_count":20352629,"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":["benchmark","browser","bun","deno","javascript","node"],"created_at":"2024-10-10T23:04:46.000Z","updated_at":"2025-03-16T14:31:06.047Z","avatar_url":"https://github.com/poolifier.png","language":"JavaScript","readme":"\u003ch1 align=center\u003etatami-ng\u003c/h1\u003e\n\n\u003ch2 align=center\u003eCross JavaScript runtime benchmarking library and CLI\u003c/h2\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n[![GitHub commit activity (master)](https://img.shields.io/github/commit-activity/m/poolifier/tatami-ng/master?color=brightgreen\u0026logo=github)](https://github.com/poolifier/tatami-ng/graphs/commit-activity)\n[![Npm Version](https://badgen.net/npm/v/tatami-ng?icon=npm)](https://www.npmjs.com/package/tatami-ng)\n[![JSR Version](https://jsr.io/badges/@poolifier/tatami-ng)](https://jsr.io/@poolifier/tatami-ng)\n[![CI Workflow](https://github.com/poolifier/tatami-ng/actions/workflows/ci.yml/badge.svg)](https://github.com/poolifier/tatami-ng/actions/workflows/ci.yml)\n[![PRs Welcome](https://badgen.net/static/PRs/welcome/green)](https://makeapullrequest.com)\n\n\u003c/div\u003e\n\n- CLI and JS library support ✔\n- Library API backward compatible with [mitata](https://github.com/evanwashere/mitata) up to version 0.1.14 ✔\n- Benchmark latency and throughput ✔\n- Support for sync and async benchmark ✔\n- Advanced benchmark statistics: significance, error margin, variance, standard deviation, p-quantiles, ... ✔\n- Multiple JS runtime support at zero cost abstraction (primary support for node, deno, bun and browsers but works with all JS runtime) ✔\n- Support for CommonJS, ESM and TypeScript ✔\n\n## Table of contents\n\n- [Library installation](#library-installation)\n  - [Node](#node)\n    - [npmjs](#npmjs)\n    - [JSR](#jsr)\n  - [Deno](#deno)\n  - [Bun](#bun)\n    - [npmjs](#npmjs-1)\n    - [JSR](#jsr-1)\n  - [Browser](#browser)\n- [Library usage example](#library-usage-example)\n- [CLI installation](#cli-installation)\n  - [Node](#node-1)\n  - [Deno](#deno-1)\n  - [Bun](#bun-1)\n- [CLI standalone binary](#cli-standalone-binary)\n  - [Deno](#deno-2)\n  - [Bun](#bun-2)\n- [CLI usage examples](#cli-usage-examples)\n- [Development](#development)\n- [License](#license)\n\n## Library installation\n\n### Node\n\n#### npmjs\n\n```shell\nnpm install tatami-ng\n```\n\n#### JSR\n\n```shell\nnpx jsr add @poolifier/tatami-ng\n```\n\n### Deno\n\n```shell\ndeno add @poolifier/tatami-ng\n```\n\nDeno versions \u003e= 1.40.x are supported.\n\nThe `--allow-hrtime` permission flag is recommended to allow high-resolution time measurement with Deno v1.x.x.\n\n### Bun\n\n#### npmjs\n\n```shell\nbun add tatami-ng\n```\n\n#### JSR\n\n```shell\nbunx jsr add @poolifier/tatami-ng\n```\n\nBun versions \u003e= 1.x are supported.\n\n### Browser\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```js\n\u003cscript type=\"module\"\u003e\nimport {\n ...\n} from 'https://cdn.jsdelivr.net/npm/tatami-ng@0.8.16/dist/browser/index.js'\n\u003c/script\u003e\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n## Library usage example\n\n```js\n// adapt import to the targeted JS runtime\nimport { baseline, bench, bmf, group, run } from 'tatami-ng'\n\nbench('noop', () =\u003e {})\nbench('noop2', () =\u003e {})\n\ngroup('group', () =\u003e {\n  baseline('baseline', () =\u003e {})\n  bench('Date.now()', () =\u003e {\n    Date.now()\n  })\n  bench('performance.now()', () =\u003e {\n    performance.now()\n  })\n})\n\ngroup({ name: 'group2', summary: false }, () =\u003e {\n  bench('new Array(0)', () =\u003e {\n    new Array(0)\n  })\n  bench('new Array(1024)', () =\u003e {\n    new Array(1024)\n  })\n})\n\nawait run({\n  units: false, // print units cheatsheet (default: false)\n  silent: false, // enable/disable stdout output (default: false)\n  json: false, // enable/disable json output or set json output indentation (default: false)\n  reporter: bmf // custom reporter function (default: undefined)\n  file: 'results.json', // write json output to file (default: undefined)\n  colors: true, // enable/disable colors (default: true)\n  now: () =\u003e 1e6 * performance.now(), // custom nanoseconds timestamp function to replace default one (default: undefined)\n  samples: 128, // minimum number of benchmark samples (default: 128)\n  time: 1_000_000_000, // minimum benchmark execution time in nanoseconds (default: 1_000_000_000)\n  warmup: true, // enable/disable benchmark warmup or set benchmark warmup run(s) (default: true)\n  warmupTime: 250_000_000, // minimum warmup execution time in nanoseconds (default: 250_000_000)\n  latency: true, // enable/disable time/iter column (default: true)\n  throughput: true, // enable/disable iters/s column (default: true)\n  latencyMinMax: true, // enable/disable latency (min...max) column (default: true)\n  latencyPercentiles: false, // enable/disable latency percentile columns (default: true)\n})\n```\n\nThe [tests](./tests) directory contains more examples.\n\n## CLI installation\n\n### Node\n\n```shell\nnpm install tatami-ng -g\n```\n\n### Deno\n\n```shell\ndeno install -g --allow-read --allow-run --allow-sys -n tatami npm:tatami-ng\n```\n\n### Bun\n\n```shell\nbun add tatami-ng -g\n```\n\nEnsure the global installation directory is in your path:\n\n- Unix: `${HOME}/.bun/bin`\n- Windows: TODO\n\n## CLI standalone binary\n\nIn the cloned repository root directory, run:\n\n### Deno\n\n```shell\nbun build:cli:deno\n```\n\n### Bun\n\n```shell\nbun build:cli:bun\n```\n\nThe standalone binary in `./dist/\u003cruntime_name\u003e` can be moved to a directory in your path.\n\n## CLI usage examples\n\n```shell\ntatami --help\n```\n\n```shell\ntatami --bench 'hexdump \u003cfile\u003e' --bench 'xxd \u003cfile\u003e'\n```\n\n## Development\n\nThe JavaScript runtime environment used for development is [bun](https://bun.sh/).\n\n## License\n\nMIT © [evanwashere](https://github.com/evanwashere), [Jerome Benoit](https://github.com/jerome-benoit)\n","funding_links":["https://patreon.com/fraggle_","https://github.com/sponsors/jerome-benoit","https://buymeacoffee.com/jbenoit100n"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpoolifier%2Ftatami-ng","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpoolifier%2Ftatami-ng","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpoolifier%2Ftatami-ng/lists"}