{"_id":"terminal-size","_rev":"8-3c1606711841404721b86c2a906a8dd6","name":"terminal-size","dist-tags":{"latest":"4.0.1"},"versions":{"4.0.0":{"name":"terminal-size","version":"4.0.0","keywords":["terminal","size","console","window","width","height","columns","rows","lines","tty","redirected"],"author":{"url":"https://sindresorhus.com","name":"Sindre Sorhus","email":"sindresorhus@gmail.com"},"license":"MIT","_id":"terminal-size@4.0.0","maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"homepage":"https://github.com/sindresorhus/terminal-size#readme","bugs":{"url":"https://github.com/sindresorhus/terminal-size/issues"},"dist":{"shasum":"a0b7530518afe5f49952c58251ec6e2e3a740570","tarball":"https://registry.npmjs.org/terminal-size/-/terminal-size-4.0.0.tgz","fileCount":5,"integrity":"sha512-rcdty1xZ2/BkWa4ANjWRp4JGpda2quksXIHgn5TMjNBPZfwzJIgR68DKfSYiTL+CZWowDX/sbOo5ME/FRURvYQ==","signatures":[{"sig":"MEYCIQDFDrUSyhYqE1boQ5apBs6uIvdTsLA8FWvJlXHe9NjiLQIhALtrlbv5FQx96oLD/zmj4h5fG3/BPuFHb+FxZmpnrZFb","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":5621},"type":"module","types":"./index.d.ts","engines":{"node":">=18"},"exports":{"types":"./index.d.ts","default":"./index.js"},"funding":"https://github.com/sponsors/sindresorhus","gitHead":"e2393bccff7175e3740492b253ca967601aab22d","scripts":{"test":"xo && ava && tsd"},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"repository":{"url":"git+https://github.com/sindresorhus/terminal-size.git","type":"git"},"_npmVersion":"9.2.0","description":"Reliably get the terminal window size (columns & rows)","directories":{},"_nodeVersion":"18.18.2","_hasShrinkwrap":false,"devDependencies":{"xo":"^0.56.0","ava":"^5.3.1","tsd":"^0.29.0","execa":"^8.0.1"},"_npmOperationalInternal":{"tmp":"tmp/terminal-size_4.0.0_1699120102709_0.38355700776842205","host":"s3://npm-registry-packages"}},"4.0.1":{"name":"terminal-size","version":"4.0.1","description":"Reliably get the terminal window size (columns & rows)","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/terminal-size.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":{"types":"./index.d.ts","default":"./index.js"},"sideEffects":false,"engines":{"node":">=18"},"scripts":{"test":"xo && ava && tsd"},"keywords":["terminal","size","console","window","width","height","columns","rows","lines","tty","redirected"],"devDependencies":{"ava":"^5.3.1","execa":"^8.0.1","tsd":"^0.29.0","xo":"^0.56.0"},"gitHead":"0cbd793b9a0d3f81d85970fb3d3815c25c029435","types":"./index.d.ts","_id":"terminal-size@4.0.1","bugs":{"url":"https://github.com/sindresorhus/terminal-size/issues"},"homepage":"https://github.com/sindresorhus/terminal-size#readme","_nodeVersion":"25.3.0","_npmVersion":"11.7.0","dist":{"integrity":"sha512-avMLDQpUI9I5XFrklECw1ZEUPJhqzcwSWsyyI8blhRLT+8N1jLJWLWWYQpB2q2xthq8xDvjZPISVh53T/+CLYQ==","shasum":"4fe8cb7482aae253f042bcd0c67b61f2dde97901","tarball":"https://registry.npmjs.org/terminal-size/-/terminal-size-4.0.1.tgz","fileCount":5,"unpackedSize":6461,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQC4NAlk4U3/JHvnX1jJuUa5rQk2zSH+guCwEy/IL6XJ+AIgSDMfkng0xqePmWHa6sN+MFQ57GbNT/el0DS1JvaDFwA="}]},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/terminal-size_4.0.1_1770009806064_0.38460371924160697"},"_hasShrinkwrap":false}},"time":{"created":"2023-11-04T17:48:22.708Z","modified":"2026-02-02T05:23:26.349Z","1.0.0":"2016-12-01T09:23:21.387Z","1.0.1":"2016-12-01T09:37:17.996Z","1.0.2":"2016-12-01T09:43:57.118Z","4.0.0":"2023-11-04T17:48:22.924Z","4.0.1":"2026-02-02T05:23:26.211Z"},"bugs":{"url":"https://github.com/sindresorhus/terminal-size/issues"},"author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"license":"MIT","homepage":"https://github.com/sindresorhus/terminal-size#readme","keywords":["terminal","size","console","window","width","height","columns","rows","lines","tty","redirected"],"repository":{"type":"git","url":"git+https://github.com/sindresorhus/terminal-size.git"},"description":"Reliably get the terminal window size (columns & rows)","maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"readme":"# terminal-size\n\n> Reliably get the terminal window size\n\nBecause [`process.stdout.columns`](https://nodejs.org/api/tty.html#tty_writestream_columns) doesn't exist when run [non-interactively](http://www.tldp.org/LDP/abs/html/intandnonint.html), for example, in a child process or when piped. This module even works when all the TTY file descriptors are redirected!\n\nConfirmed working on macOS, Linux, and Windows.\n\n## Install\n\n```sh\nnpm install terminal-size\n```\n\n## Usage\n\n```js\nimport terminalSize from 'terminal-size';\n\nterminalSize();\n//=> {columns: 143, rows: 24}\n```\n\n## API\n\n### terminalSize()\n\nReturns an `object` with `columns` and `rows` properties.\n\n## Related\n\n- [terminal-size-cli](https://github.com/sindresorhus/terminal-size-cli) - CLI for this module\n","readmeFilename":"readme.md"}