{"id":13527870,"url":"https://github.com/FormidableLabs/nodejs-dashboard","last_synced_at":"2025-04-01T10:32:56.062Z","repository":{"id":11810807,"uuid":"70454725","full_name":"FormidableLabs/nodejs-dashboard","owner":"FormidableLabs","description":" Telemetry dashboard for node.js apps from the terminal!","archived":true,"fork":false,"pushed_at":"2022-03-03T22:32:15.000Z","size":996,"stargazers_count":3912,"open_issues_count":15,"forks_count":146,"subscribers_count":107,"default_branch":"master","last_synced_at":"2025-03-26T22:04:24.509Z","etag":null,"topics":["monitoring","nodejs","telemetry"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/FormidableLabs.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-10-10T05:26:56.000Z","updated_at":"2025-03-22T16:41:42.000Z","dependencies_parsed_at":"2022-08-07T06:16:36.909Z","dependency_job_id":null,"html_url":"https://github.com/FormidableLabs/nodejs-dashboard","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FormidableLabs%2Fnodejs-dashboard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FormidableLabs%2Fnodejs-dashboard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FormidableLabs%2Fnodejs-dashboard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FormidableLabs%2Fnodejs-dashboard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FormidableLabs","download_url":"https://codeload.github.com/FormidableLabs/nodejs-dashboard/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246625732,"owners_count":20807811,"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":["monitoring","nodejs","telemetry"],"created_at":"2024-08-01T06:02:04.503Z","updated_at":"2025-04-01T10:32:55.731Z","avatar_url":"https://github.com/FormidableLabs.png","language":"JavaScript","readme":"\u003ch1 align=\"center\"\u003enodejs-dashboard\u003c/h1\u003e\n\n\u003ch4 align=\"center\"\u003e\n  Telemetry dashboard for node.js apps from the terminal!\n\u003c/h4\u003e\n\n[![Build Status](https://travis-ci.com/FormidableLabs/nodejs-dashboard.svg?branch=master)](https://travis-ci.com/FormidableLabs/nodejs-dashboard)\n\n![http://g.recordit.co/WlUvKhXqnp.gif](http://g.recordit.co/WlUvKhXqnp.gif)\n\nDetermine in realtime what's happening inside your node process from the terminal. No need to instrument code to get the deets. Also splits stderr/stdout to help spot errors sooner.\n\n[Install](#install) | [Setup](#setup) | [Usage](#usage) | [Using with other programs](#launching-your-app-with-something-other-than-node) | [CLI options](#cli-options) | [Customizing layouts](#customizing-layouts)\n---------------|---------------------|-----------------|-----------------|------------------------------------------|----------------------\n\nNOTE: This module isn't designed for production use and should be limited to development environments.\n\n### Install\n\nThe preferred method is global install.  `npm install -g nodejs-dashboard`\n\nLocal install works also; just use `./node_modules/.bin/nodejs-dashboard` instead of `nodejs-dashboard` to execute.\n\n### Setup\n\nThe dashboard agent needs to be required by your app. There are two ways to do this:\n\n#### Including via code\n\nFrom within a `dev.index.js` script or other dev entry point simply require the `nodejs-dashboard` module.\n\n```js\n// dev.index.js\nrequire(\"nodejs-dashboard\");\nrequire(\"./index\");\n```\n\nTo launch: `nodejs-dashboard node dev.index.js`\n\n#### Including via preload argument\n\nThis method utilizes Node's `-r` flag to introduce the `nodejs-dashboard` module. In this setup no code modifications are required. This is functionally equivalent to the above example.\n\nTo launch: `nodejs-dashboard -- node -r nodejs-dashboard index.js`\n\n#### Fonts\n\n`nodejs-dashboard` uses the [Braille Unicode character set](https://en.wikipedia.org/wiki/Braille_Patterns#Chart) to show graphs via the [node-drawille](https://github.com/madbence/node-drawille) dependancy. Ensure your terminal program\\'s font supports this character set.\n\n#### Environment variables\n\n`nodejs-dashboard` uses several environment variables to modify its behavior. These include some required values to prevent mangled output.\n\nVariable | Required | Source | Description |\n--- | --- | --- | --- |\nTERM | required | [blessed](https://github.com/chjj/blessed) | Terminal value matching terminal program |\nLANG | required | [blessed](https://github.com/chjj/blessed) | Matches encoding of terminal program to display font correctly |\nFORCE_COLOR | optional | [chalk](https://github.com/chalk/chalk) | Used to force color output by the subprocess |\n\n### Usage\n\nPress `?` to see a list of keybindings. Use arrow keys to change the layout.\n\nYou may want to add an npm script to to your `package.json` to launch your app using nodejs-dashboard using one of the options above. Example:\n\n```js\n\"scripts\": {\n  \"dev\": \"nodejs-dashboard -- node -r nodejs-dashboard index.js\"\n}\n```\n\n#### Passing arguments\n\nIf your app requires additional arguments you'll need to use the `--` flag to separate them from `nodejs-dashboard` options. For example:\n\n`nodejs-dashboard --port=8002 -- node -m=false --bar=true index.js`\n\n#### Launching your app with something other than `node`\n\nMost CLI interfaces provide a mechanism for launching other tools. If you're looking to use something like [nodemon](https://github.com/remy/nodemon) or [babel](https://github.com/babel/babel/tree/master/packages/babel-cli) checkout the exec options provided by the CLI.\n\n```bash\n% nodemon --exec \"nodejs-dashboard babel-node\" src/index.js\n```\n\n#### Docker and Docker Compose support\n\n`nodejs-dashboard` can run inside a container if that container has a [TTY](https://en.wikipedia.org/wiki/Pseudoterminal) allocated to it. The [Docker documentation](https://docs.docker.com/engine/reference/run/#foreground) shows how to run a container with an interactive terminal session. Additional the [Docker Compose documentation](https://docs.docker.com/compose/reference/run/) indicates that `docker-compose run` defaults to allocating a TTY and `docker-compose up` defaults to not allocating one.\n\n#### CLI options\n\nUsage: `nodejs-dashboard [options] -- [node] [script] [arguments]`\n\n```\nOptions:\n  -h, --help                  output usage information\n  -e, --eventdelay [ms]       Minimum threshold for event loop reporting, default 10ms\n  -l, --layouts [file]        Path to file or npm module with layouts\n  -p, --port [port]           Socket listener port\n  -r, --refreshinterval [ms]  Metrics refresh interval, default 1000ms\n  -s, --settings [settings]   Overrides layout settings for given view types           \n  -V, --version               output the version number\n```\n\n##### `--eventdelay`\nThis tunes the minimum threshold for reporting event loop delays. The default value is `10ms`. Any delay below this value will be reported at `0`.\n\n##### `--layouts`\nOptionally supply a custom layout configuration (for details, see [Customizing Layouts](/LAYOUTS.md)). Default: [`lib/default-layout-config.js`](./lib/default-layout-config.js)\n\n##### `--port`\nUnder the hood the dashboard utilizes SocketIO with a default port of `9838`. If this conflicts with an existing service you can optionally change this value.\n\n##### `--refreshinterval`\nSpecifies the interval in milliseconds that the metrics should be refreshed. The default is 1000 ms (1 second).\n\n##### `--settings`\nOverrides default or layout settings for views. Option value `settings` should have a format `\u003cview_type.setting.path\u003e=\u003cvalue\u003e,...`. For example `--settings log.scrollback=100` will override `scrollback` setting for any view of `log` type (nested paths can be used if needed). For details about layouts, see [Customizing Layouts](/LAYOUTS.md)).\n\n## Maintenance Status\n\n**Archived:** This project is no longer maintained by Formidable. We are no longer responding to issues or pull requests unless they relate to security concerns. We encourage interested developers to fork this project and make it their own!\n","funding_links":[],"categories":["JavaScript","NodeJS","📟 Terminal","The Web Backend"],"sub_categories":["Utils"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FFormidableLabs%2Fnodejs-dashboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FFormidableLabs%2Fnodejs-dashboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FFormidableLabs%2Fnodejs-dashboard/lists"}