Skip to content

Commit b19b1ae

Browse files
docs: add quick start guide
1 parent 0dee2c5 commit b19b1ae

1 file changed

Lines changed: 37 additions & 0 deletions

File tree

‎Readme.md‎

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -280,3 +280,40 @@ The original author of Express is [TJ Holowaychuk](https://github.com/tj)
280280
[ossf-scorecard-visualizer]: https://ossf.github.io/scorecard-visualizer/#/projects/github.com/expressjs/express
281281
[Code of Conduct]: https://github.com/expressjs/.github/blob/HEAD/CODE_OF_CONDUCT.md
282282
[Contributing Guide]: https://github.com/expressjs/.github/blob/HEAD/CONTRIBUTING.md
283+
284+
285+
## Quick Start
286+
287+
To create a basic Express application:
288+
289+
```bash
290+
mkdir my-express-app
291+
cd my-express-app
292+
npm init -y
293+
npm install express
294+
```
295+
296+
Create an `app.js` file:
297+
298+
```javascript
299+
const express = require('express');
300+
301+
const app = express();
302+
const PORT = 3000;
303+
304+
app.get('/', (req, res) => {
305+
res.send('Hello, Express!');
306+
});
307+
308+
app.listen(PORT, () => {
309+
console.log(`Server running on http://localhost:${PORT}`);
310+
});
311+
```
312+
313+
Run the application:
314+
315+
```bash
316+
node app.js
317+
```
318+
319+
Then open `http://localhost:3000` in a web browser.

0 commit comments

Comments
 (0)