{"_id":"supports-hyperlinks","_rev":"202550","name":"supports-hyperlinks","description":"Detect if your terminal emulator supports hyperlinks","dist-tags":{"latest":"3.0.0"},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"time":{"modified":"2023-03-21T06:29:18.000Z","created":"2017-11-28T01:20:21.493Z","3.0.0":"2023-03-08T10:05:24.926Z","2.3.0":"2022-09-06T04:55:37.030Z","2.2.0":"2021-04-06T23:11:02.630Z","2.1.0":"2020-02-07T00:13:57.198Z","2.0.0":"2019-07-17T18:11:12.257Z","1.0.1":"2017-11-28T01:50:58.193Z","1.0.0":"2017-11-28T01:20:21.493Z"},"users":{},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"versions":{"3.0.0":{"name":"supports-hyperlinks","version":"3.0.0","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=14.18"},"scripts":{"prepublishOnly":"npm run create-types","test":"xo && nyc ava && tsc","create-types":"tsc --project declaration.tsconfig.json"},"browser":"browser.js","keywords":["link","terminal","hyperlink","cli"],"dependencies":{"has-flag":"^4.0.0","supports-color":"^7.0.0"},"devDependencies":{"@tsconfig/node14":"^1.0.3","@types/supports-color":"^8.1.1","ava":"^2.2.0","codecov":"^3.5.0","nyc":"^14.1.1","typescript":"^4.9.5","xo":"^0.24.0"},"nyc":{"reporter":["lcov","text"]},"types":"./index.d.ts","gitHead":"99da35502fdfe4b9eb0d650389c6557e6251ef3b","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@3.0.0","_nodeVersion":"18.14.2","_npmVersion":"9.2.0","dist":{"shasum":"c711352a5c89070779b4dad54c05a2f14b15c94b","size":3282,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-3.0.0.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-3.0.0.tgz"},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks_3.0.0_1678269924748_0.4712278572497024"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-03-08T10:05:24.926Z","publish_time":1678269924926,"_cnpm_publish_time":1678269924926},"2.3.0":{"name":"supports-hyperlinks","version":"2.3.0","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=8"},"scripts":{"prepublishOnly":"npm run create-types","test":"xo && nyc ava","create-types":"tsc index.js --allowJs  --declaration --emitDeclarationOnly"},"browser":"browser.js","keywords":["link","terminal","hyperlink","cli"],"dependencies":{"has-flag":"^4.0.0","supports-color":"^7.0.0"},"devDependencies":{"ava":"^2.2.0","codecov":"^3.5.0","nyc":"^14.1.1","typescript":"^3.7.2","xo":"^0.24.0"},"nyc":{"reporter":["lcov","text"]},"types":"./index.d.ts","gitHead":"4cb672f76ca566f82c541b2a177aa6205875a0a6","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@2.3.0","_nodeVersion":"14.19.3","_npmVersion":"8.3.2","dist":{"shasum":"3943544347c1ff90b15effb03fc14ae45ec10624","size":3083,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-2.3.0.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-2.3.0.tgz"},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks_2.3.0_1662440136874_0.16153616125736447"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-09-06T04:57:30.766Z","publish_time":1662440137030,"_cnpm_publish_time":1662440137030},"2.2.0":{"name":"supports-hyperlinks","version":"2.2.0","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=8"},"scripts":{"prepublishOnly":"npm run create-types","test":"xo && nyc ava","create-types":"tsc index.js --allowJs  --declaration --emitDeclarationOnly"},"browser":"browser.js","keywords":["link","terminal","hyperlink","cli"],"dependencies":{"has-flag":"^4.0.0","supports-color":"^7.0.0"},"devDependencies":{"ava":"^2.2.0","codecov":"^3.5.0","nyc":"^14.1.1","typescript":"^3.7.2","xo":"^0.24.0"},"nyc":{"reporter":["lcov","text"]},"gitHead":"66834a8a4ccc07f9af6364778fcaa0666b61eccb","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@2.2.0","_nodeVersion":"14.3.0","_npmVersion":"7.8.0","dist":{"shasum":"4f77b42488765891774b70c79babd87f9bd594bb","size":3011,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-2.2.0.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-2.2.0.tgz"},"_npmUser":{"name":"jamestalmage","email":"james@talmage.io"},"directories":{},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks_2.2.0_1617750662491_0.6291010861567068"},"_hasShrinkwrap":false,"publish_time":1617750662630,"_cnpm_publish_time":1617750662630,"_cnpmcore_publish_time":"2021-12-13T11:52:28.585Z"},"2.1.0":{"name":"supports-hyperlinks","version":"2.1.0","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=8"},"scripts":{"prepublishOnly":"npm run create-types","test":"xo && nyc ava","create-types":"tsc index.js --allowJs  --declaration --emitDeclarationOnly"},"browser":"browser.js","keywords":["link","terminal","hyperlink","cli"],"dependencies":{"has-flag":"^4.0.0","supports-color":"^7.0.0"},"devDependencies":{"ava":"^2.2.0","codecov":"^3.5.0","nyc":"^14.1.1","typescript":"^3.7.2","xo":"^0.24.0"},"nyc":{"reporter":["lcov","text"]},"gitHead":"6af53f634749394fea2de362b7866f0a57d44607","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@2.1.0","_nodeVersion":"12.15.0","_npmVersion":"6.13.4","dist":{"shasum":"f663df252af5f37c5d49bbd7eeefa9e0b9e59e47","size":3016,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-2.1.0.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-2.1.0.tgz"},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmUser":{"name":"jamestalmage","email":"james@talmage.io"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks_2.1.0_1581034437069_0.3445899160452104"},"_hasShrinkwrap":false,"publish_time":1581034437198,"_cnpm_publish_time":1581034437198},"2.0.0":{"name":"supports-hyperlinks","version":"2.0.0","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=8"},"scripts":{"test":"xo && nyc ava"},"browser":"browser.js","keywords":["link","terminal","hyperlink","cli"],"dependencies":{"has-flag":"^4.0.0","supports-color":"^7.0.0"},"devDependencies":{"ava":"^2.2.0","codecov":"^3.5.0","nyc":"^14.1.1","xo":"^0.24.0"},"nyc":{"reporter":["lcov","text"]},"gitHead":"d69899797030a99ebf024b0c74e13027c99a6986","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@2.0.0","_nodeVersion":"10.14.1","_npmVersion":"6.10.1","dist":{"shasum":"b1b94a159e9df00b0a554b2d5f0e0a89690334b0","size":2942,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-2.0.0.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-2.0.0.tgz"},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmUser":{"name":"jamestalmage","email":"james@talmage.io"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks_2.0.0_1563387072109_0.9532700614996101"},"_hasShrinkwrap":false,"publish_time":1563387072257,"_cnpm_publish_time":1563387072257},"1.0.1":{"name":"supports-hyperlinks","version":"1.0.1","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=4"},"scripts":{"test":"xo && nyc ava"},"files":["index.js","browser.js"],"browser":"browser.js","keywords":["link","terminal","hyperlink","cli"],"dependencies":{"has-flag":"^2.0.0","supports-color":"^5.0.0"},"devDependencies":{"ava":"^0.20.0","babel-preset-env":"^1.6.1","babel-preset-stage-3":"^6.24.1","codecov":"^2.2.0","nyc":"^11.0.0","xo":"^0.18.2"},"ava":{"babel":{"presets":["env","stage-3"]}},"nyc":{"reporter":["lcov","text"]},"gitHead":"fe34a2736bcb108c310d62e94284f610ed8b203b","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@1.0.1","_npmVersion":"5.5.1","_nodeVersion":"8.9.1","_npmUser":{"name":"jamestalmage","email":"james@talmage.io"},"dist":{"shasum":"71daedf36cc1060ac5100c351bb3da48c29c0ef7","size":2885,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-1.0.1.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-1.0.1.tgz"},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks-1.0.1.tgz_1511833857356_0.612168702762574"},"directories":{},"publish_time":1511833858193,"_cnpm_publish_time":1511833858193,"_hasShrinkwrap":false},"1.0.0":{"name":"supports-hyperlinks","version":"1.0.0","description":"Detect if your terminal emulator supports hyperlinks","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jamestalmage/supports-hyperlinks.git"},"author":{"name":"James Talmage","email":"james@talmage.io","url":"github.com/jamestalmage"},"engines":{"node":">=4"},"scripts":{"test":"xo && nyc ava"},"files":["index.js","browser.js"],"browser":"browser.js","keywords":[],"dependencies":{"has-flag":"^2.0.0","supports-color":"^5.0.0"},"devDependencies":{"ava":"^0.20.0","babel-preset-env":"^1.6.1","babel-preset-stage-3":"^6.24.1","codecov":"^2.2.0","nyc":"^11.0.0","xo":"^0.18.2"},"ava":{"babel":{"presets":["env","stage-3"]}},"nyc":{"reporter":["lcov","text"]},"gitHead":"2680b8599abc465242826b90a6b9075378aff166","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","_id":"supports-hyperlinks@1.0.0","_npmVersion":"5.5.1","_nodeVersion":"8.9.1","_npmUser":{"name":"jamestalmage","email":"james@talmage.io"},"dist":{"shasum":"5aa39343ee70cdec29e4ebad68d4398a84b5d5ab","size":2866,"noattachment":false,"key":"/supports-hyperlinks/-/supports-hyperlinks-1.0.0.tgz","tarball":"http://name.csiicloud.com:7001/supports-hyperlinks/download/supports-hyperlinks-1.0.0.tgz"},"maintainers":[{"name":"jamestalmage","email":""},{"name":"novemberborn","email":""},{"name":"sindresorhus","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/supports-hyperlinks-1.0.0.tgz_1511832020464_0.8140476217959076"},"directories":{},"publish_time":1511832021493,"_hasShrinkwrap":false,"_cnpm_publish_time":1511832021493}},"readme":"# supports-hyperlinks [![Build Status](https://travis-ci.org/jamestalmage/supports-hyperlinks.svg?branch=master)](https://travis-ci.org/jamestalmage/supports-hyperlinks) [![codecov](https://codecov.io/gh/jamestalmage/supports-hyperlinks/badge.svg?branch=master)](https://codecov.io/gh/jamestalmage/supports-hyperlinks?branch=master)\n\n> Detect whether a terminal emulator supports hyperlinks\n\nTerminal emulators are [starting to support hyperlinks](https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda). While many terminals have long detected URL's and linkified them, allowing you to Command-Click or Control-Click them to open a browser, you were forced to print the long unsightly URL's on the screen. As of spring 2017 [a few terminals](https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda) began supporting HTML like links, where the link text and destination could be specified separately.\n\nThis module allows you to detect if hyperlinks are supported in the current Terminal.\n\nAs this is a new development, we anticipate the list of supported Terminals to grow rapidly. Please open an issue or submit a PR as new Terminals implement support.\n\n## Install\n\n```\n$ npm install supports-hyperlinks\n```\n\n\n## Usage\n\n```js\nconst supportsHyperlinks = require('supports-hyperlinks');\n\nif (supportsHyperlinks.stdout) {\n\tconsole.log('Terminal stdout supports hyperlinks');\n}\n\nif (supportsHyperlinks.stderr) {\n\tconsole.log('Terminal stderr supports hyperlinks');\n}\n```\n\n## API\n\nReturns an `Object` with a `stdout` and `stderr` property for testing either streams. Each property is a `boolean`, indicating whether or not hyperlinks are supported.\n\n## Info\n\nObeys the `--no-hyperlinks`, `--hyperlink=always`, and `--hyperlink=never` CLI flags.\n\nCan be overridden by the user with the flags `--hyperlinks=always` and `--no-hyperlinks`. For situations where using those flags are not possible, add the environment variable `FORCE_HYPERLINK=1` to forcefully enable hyperlinks or `FORCE_HYPERLINK=0` to forcefully disable. The use of `FORCE_HYPERLINK` overrides all other hyperlink support checks.\n\n## Related\n\n  * [`hyperlinker`](https://github.com/jamestalmage/hyperlinker): Write hyperlinks for the Terminal.\n\n## License\n\nMIT © [James Talmage](https://github.com/jamestalmage)\n","_attachments":{},"homepage":"https://github.com/jamestalmage/supports-hyperlinks#readme","bugs":{"url":"https://github.com/jamestalmage/supports-hyperlinks/issues"},"license":"MIT"}