docs: update readme (#5994)
Before adoption: this commit came in with the history the project adopted, so no landing records it.
authored by Sebastian Beltran · committed by GitHub · parent b274047 · Browse files · 1 file·+42 added−38 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
1 file+42 added−38 removed
- other:+42 added−38 removed
Provenance
- Commit
508c740- Tree
9b2fe4c- Author
Sebastian Beltran <bjohansebas@gmail.com>- Committer
GitHub <noreply@github.com>- Parent
b274047
1 file changed+42 added−38 removed
modified:Readme.md+42 added-38 removed
1-[](http://expressjs.com/)1+[](https://expressjs.com/)2 3-**Fast, unopinionated, minimalist web framework for [Node.js](http://nodejs.org).**3+**Fast, unopinionated, minimalist web framework for [Node.js](https://nodejs.org).**4 5 **This project has a [Code of Conduct][].**6 7 ## Table of contents17 unmodified lines25 [![OpenSSF Scorecard Badge][ossf-scorecard-badge]][ossf-scorecard-visualizer]26 27 28 ```js29-const express = require('express')29+import express from 'express'30+31 const app = express()32 32-app.get('/', function (req, res) {33+app.get('/', (req, res) => {34 res.send('Hello World')35 })36 37 app.listen(3000)4 unmodified lines42 This is a [Node.js](https://nodejs.org/en/) module available through the43 [npm registry](https://www.npmjs.com/).44 45 Before installing, [download and install Node.js](https://nodejs.org/en/download/).45-Node.js 0.10 or higher is required.46+Node.js 18 or higher is required.47 48 If this is a brand new project, make sure to create a `package.json` first with49 the [`npm init` command](https://docs.npmjs.com/creating-a-package-json-file).50 51 Installation is done using the52 [`npm install` command](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):53 53-```console54-$ npm install express54+```bash55+npm install express56 ```57 57-Follow [our installing guide](http://expressjs.com/en/starter/installing.html)58+Follow [our installing guide](https://expressjs.com/en/starter/installing.html)59 for more information.60 61 ## Features62 6 unmodified lines69 * Executable for generating applications quickly70 71 ## Docs & Community72 72- * [Website and Documentation](http://expressjs.com/) - [[website repo](https://github.com/expressjs/expressjs.com)]73- * [#express](https://web.libera.chat/#express) on [Libera Chat](https://libera.chat) IRC73+ * [Website and Documentation](https://expressjs.com/) - [[website repo](https://github.com/expressjs/expressjs.com)]74 * [GitHub Organization](https://github.com/expressjs) for Official Middleware & Modules75- * Visit the [Wiki](https://github.com/expressjs/express/wiki)76- * [Google Group](https://groups.google.com/group/express-js) for discussion77- * [Gitter](https://gitter.im/expressjs/express) for support and discussion75+ * [Github Discussions](https://github.com/expressjs/discussions) for discussion on the development and usage of Express76 79-**PROTIP** Be sure to read [Migrating from 3.x to 4.x](https://github.com/expressjs/express/wiki/Migrating-from-3.x-to-4.x) as well as [New features in 4.x](https://github.com/expressjs/express/wiki/New-features-in-4.x).77+**PROTIP** Be sure to read the [migration guide to v5](https://expressjs.com/en/guide/migrating-5)78 79 ## Quick Start80 81 The quickest way to get started with express is to utilize the executable [`express(1)`](https://github.com/expressjs/generator) to generate an application as shown below:82 83 Install the executable. The executable's major version will match Express's:84 87-```console88-$ npm install -g express-generator@485+```bash86+npm install -g express-generator@487 ```88 89 Create the app:90 93-```console94-$ express /tmp/foo && cd /tmp/foo91+```bash92+express /tmp/foo && cd /tmp/foo93 ```94 95 Install dependencies:96 99-```console100-$ npm install97+```bash98+npm install99 ```100 101 Start the server:102 105-```console106-$ npm start103+```bash104+npm start105 ```106 107 View the website at: http://localhost:3000108 3 unmodified lines112 it a great solution for single page applications, websites, hybrids, or public113 HTTP APIs.114 115 Express does not force you to use any specific ORM or template engine. With support for over118- 14 template engines via [Consolidate.js](https://github.com/tj/consolidate.js),116+ 14 template engines via [@ladjs/consolidate](https://github.com/ladjs/consolidate),117 you can quickly craft your perfect framework.118 119 ## Examples120 123- To view the examples, clone the Express repo and install the dependencies:121+ To view the examples, clone the Express repository:122 125-```console126-$ git clone https://github.com/expressjs/express.git --depth 1127-$ cd express128-$ npm install123+```bash124+git clone https://github.com/expressjs/express.git --depth 1 && cd express125 ```126 127+ Then install the dependencies:128+129+```bash130+npm install131+```132+133 Then run whichever example you want:134 133-```console134-$ node examples/content-negotiation135+```bash136+node examples/content-negotiation137 ```138 139 ## Contributing140 141 [![Linux Build][github-actions-ci-image]][github-actions-ci-url]140- [![Windows Build][appveyor-image]][appveyor-url]142 [![Test Coverage][coveralls-image]][coveralls-url]143 144 The Express.js project welcomes all constructive contributions. Contributions take many forms,145 from code for bug fixes and enhancements, to additions and fixes to documentation, additional6 unmodified lines152 If you discover a security vulnerability in Express, please see [Security Policies and Procedures](Security.md).153 154 ### Running Tests155 155-To run the test suite, first install the dependencies, then run `npm test`:156+To run the test suite, first install the dependencies:157 157-```console158-$ npm install159-$ npm test158+```bash159+npm install160 ```161 162+Then run `npm test`:163+164+```bash165+npm test166+```167+168 ## People169 170 The original author of Express is [TJ Holowaychuk](https://github.com/tj)171 77 unmodified lines249 ## License250 251 [MIT](LICENSE)252 247-[appveyor-image]: https://badgen.net/appveyor/ci/dougwilson/express/master?label=windows248-[appveyor-url]: https://ci.appveyor.com/project/dougwilson/express253 [coveralls-image]: https://badgen.net/coveralls/c/github/expressjs/express/master254 [coveralls-url]: https://coveralls.io/r/expressjs/express?branch=master251-[github-actions-ci-image]: https://badgen.net/github/checks/expressjs/express/master?label=linux255+[github-actions-ci-image]: https://badgen.net/github/checks/expressjs/express/master?label=CI256 [github-actions-ci-url]: https://github.com/expressjs/express/actions/workflows/ci.yml257 [npm-downloads-image]: https://badgen.net/npm/dm/express258 [npm-downloads-url]: https://npmcharts.com/compare/express?minimal=true259 [npm-install-size-image]: https://badgen.net/packagephobia/install/express6 unmodified lines