├── .gitattributes ├── nodemon.json ├── tsconfig.json ├── src └── server.ts ├── package.json ├── LICENSE └── README.md /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /nodemon.json: -------------------------------------------------------------------------------- 1 | { 2 | "watch": ["src"], 3 | "ext": "ts", 4 | "exec": "npx ts-node src/server.ts" 5 | } 6 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "esnext", 4 | "module": "commonjs", 5 | "strict": true, 6 | "esModuleInterop": true, 7 | "skipLibCheck": true, 8 | "outDir": "dist" 9 | }, 10 | "include": ["src/**/*"] 11 | } 12 | -------------------------------------------------------------------------------- /src/server.ts: -------------------------------------------------------------------------------- 1 | import express from "express"; 2 | 3 | const app = express(); 4 | const PORT = 8000; 5 | 6 | // روت ساده 7 | app.get("/", (req, res) => { 8 | res.send("Server is running!"); 9 | }); 10 | 11 | // شروع به گوش دادن روی پورت 12 | app.listen(PORT, () => { 13 | console.log(`Server is running on http://localhost:${PORT}`); 14 | }); 15 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "video-confrence-server", 3 | "version": "1.0.0", 4 | "main": "index.js", 5 | "scripts": { 6 | "dev": "nodemon", 7 | "start": "node dist/server.js", 8 | "build": "tsc" 9 | }, 10 | "keywords": [], 11 | "author": "", 12 | "license": "ISC", 13 | "description": "", 14 | "dependencies": { 15 | "express": "^4.21.1" 16 | }, 17 | "devDependencies": { 18 | "@types/express": "^5.0.0", 19 | "@types/node": "^22.10.1", 20 | "nodemon": "^3.1.7", 21 | "ts-node": "^10.9.2", 22 | "typescript": "^5.7.2" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2024 Milad Joodi 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | # Simple Node.js Server with Express 🚀 3 | 4 | This is a basic Node.js server setup using **Express** and **Nodemon**, created as a starting point for backend projects. Perfect for beginners who want to explore Express.js! 🛠️ 5 | 6 | ## Features ✨ 7 | 8 | - Minimal setup with **Node.js** and **Express**. 9 | - Uses **Nodemon** for automatic server reload on code changes. 🔄 10 | - Clean and simple structure to get started quickly. 11 | 12 | --- 13 | 14 | ## Installation & Usage 📝 15 | 16 | ```bash 17 | 1. git clone https://github.com/MiladJoodi/Express_Starter_Project.git 18 | cd Express_Starter_Project 19 | 20 | 2. Install dependencies 21 | npm install 22 | 23 | 3. Start the server in development mode 24 | npm run dev 25 | 26 | When the server starts successfully, you'll see this message in the console: 27 | Server is running on http://localhost:8000 28 | ``` 29 | ![Image](https://s32.picofile.com/file/8481043392/087.png) 30 | 31 | ## How it Works ⚙️ 32 | 33 | - **Express** handles the routing and backend logic. 34 | - **Nodemon** automatically restarts the server when you make changes to the code, improving development efficiency. 35 | - You can access the server on `http://localhost:8000` after running the project. 36 | 37 | --- 38 | 39 | ## About 🤖 40 | 41 | This project was scaffolded with the help of **GitHub Copilot**, making it a fast and easy way to bootstrap a server with **Node.js** and **Express**. 42 | 43 | 44 | ## Let's Connect 🌐 45 | 46 | - [Dev.to](https://dev.to/Joodi) 47 | - [Medium](https://medium.com/@Joodi) 48 | - [LinkedIn](https://www.linkedin.com/in/MiladJoodi) 49 | 50 | Happy coding! 🎉 51 | 52 | --------------------------------------------------------------------------------