# Quick start node

1. Create Empty folder on desktop
2. Open with VScode and open terminal
3. &#x20;Use the following commands

Create node

```
npm init -y
```

install dependencies

```
npm i express nodemon 
```

4. Make changes to the package.json file. Like if you are using nodemon, add what is missing under the scripts dictionary

```
"scripts": {
 "test": "echo "Error: no test specified" && exit 1"
 "start": "node index.js", 
 "dev": "nodemon index.js",
```

5. Make a file name index.js (this is your main server with node)

```
const express = require('express'); 
const app = express(); 
const port = process.env.PORT || 3000;
app.listen(port, () => {
               console.log(Server running on http://localhost:${port}); 
});
```

6. start node

```
npm run start 
```

or&#x20;

```
npm run dev  
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://baric6.gitbook.io/barics-knowledge-base/development/lanuages/node/quick-start-node.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
