From b7cf9ad458ac6fd690e37171fdfaab57a2d58e72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Mon, 13 Mar 2023 11:15:57 +0100 Subject: [PATCH] docs: update badges and content --- README.md | 59 +++++++++++++++++++++++++------------------------------ 1 file changed, 27 insertions(+), 32 deletions(-) diff --git a/README.md b/README.md index c4bd37c..1bb0aac 100644 --- a/README.md +++ b/README.md @@ -1,44 +1,33 @@ -![listhen](https://user-images.githubusercontent.com/904724/101662837-46845280-3a4a-11eb-9e9a-d5399e8af753.png) - # 👂 listhen -> Elegant http listener +An elegant HTTP listener. [![npm version][npm-version-src]][npm-version-href] [![npm downloads][npm-downloads-src]][npm-downloads-href] -[![Github Actions][github-actions-src]][github-actions-href] [![Codecov][codecov-src]][codecov-href] - -✔️ Promisified interface for listening and closing server - -✔️ Works with express/connect or plain http handle function - -✔️ Support HTTP and HTTPS - -✔️ Automatically assign a port or fallback to human friendly alternative (with [get-port-please](https://github.com/unjs/get-port-please)) - -✔️ Automatically generate listening URL and show on console - -✔️ Automatically copy URL to clipboard - -✔️ Automatically open in browser (opt-in) - -✔️ Automatically generate self-signed certificate - -✔️ Automatically detect test and production environments - -✔️ Automatically close on exit signal - -✔️ Gracefully shutdown server with [http-shutdown](https://github.com/thedillonb/http-shutdown) +[![License][license-src]][license-href] +[![JSDocs][jsdocs-src]][jsdocs-href] + +## Features + +- Promisified interface for listening and closing server +- Work with express/connect or plain http handle function +- Support HTTP and HTTPS +- Assign a port or fallback to human friendly alternative (with [get-port-please](https://github.com/unjs/get-port-please)) +- Generate listening URL and show on console +- Copy URL to clipboard (dev only by default) +- Open URL in browser (opt-in) +- Generate self-signed certificate +- Detect test and production environments +- Close on exit signal +- Gracefully shutdown server with [http-shutdown](https://github.com/thedillonb/http-shutdown) ## Install -Install using npm or yarn: +Install using npm: ```bash npm i listhen -# or -yarn add listhen ``` Import into your Node.js project: @@ -155,11 +144,17 @@ Automatically close when an exit signal is received on process. MIT. Made with 💖 -[npm-version-src]: https://img.shields.io/npm/v/listhen?style=flat-square +[npm-version-src]: https://img.shields.io/npm/v/listhen?style=flat&colorA=18181B&colorB=F0DB4F [npm-version-href]: https://npmjs.com/package/listhen - -[npm-downloads-src]: https://img.shields.io/npm/dm/listhen?style=flat-square +[npm-downloads-src]: https://img.shields.io/npm/dm/listhen?style=flat&colorA=18181B&colorB=F0DB4F [npm-downloads-href]: https://npmjs.com/package/listhen +[codecov-src]: https://img.shields.io/codecov/c/gh/unjs/listhen/main?style=flat&colorA=18181B&colorB=F0DB4F +[codecov-href]: https://codecov.io/gh/unjs/listhen +[license-src]: https://img.shields.io/github/license/unjs/listhen.svg?style=flat&colorA=18181B&colorB=F0DB4F +[license-href]: https://github.com/unjs/listhen/blob/main/LICENSE +[jsdocs-src]: https://img.shields.io/badge/jsDocs.io-reference-18181B?style=flat&colorA=18181B&colorB=F0DB4F +[jsdocs-href]: https://www.jsdocs.io/package/listhen + [github-actions-src]: https://img.shields.io/github/workflow/status/unjs/listhen/ci/main?style=flat-square [github-actions-href]: https://github.com/unjs/listhen/actions?query=workflow%3Aci