https://github.com/arjun-tp/boilerplate-nodejs-svelte
A lightweight and scalable boilerplate for building modern web applications using Node.js and Svelte. This setup provides a seamless integration between the frontend and backend and deployment using Docker.
https://github.com/arjun-tp/boilerplate-nodejs-svelte
boilerplate docker docker-compose javascript mongodb nodejs svelte template vite
Last synced: 4 months ago
JSON representation
A lightweight and scalable boilerplate for building modern web applications using Node.js and Svelte. This setup provides a seamless integration between the frontend and backend and deployment using Docker.
- Host: GitHub
- URL: https://github.com/arjun-tp/boilerplate-nodejs-svelte
- Owner: Arjun-tp
- Created: 2025-03-18T16:12:54.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-01T19:24:47.000Z (about 1 year ago)
- Last Synced: 2025-09-10T04:31:42.923Z (10 months ago)
- Topics: boilerplate, docker, docker-compose, javascript, mongodb, nodejs, svelte, template, vite
- Language: JavaScript
- Homepage:
- Size: 71.3 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# boilerplate-nodejs-svelte
A lightweight and scalable boilerplate for building modern web applications using Node.js and Svelte.
This setup provides a seamless integration between the frontend and backend and deployment using Docker.
### Security & Performance
- **Rate Limiting** to prevent abuse and throttling
- **CORS Enabled** to handle cross-origin requests securely
- **ESLint & Prettier** for code quality and formatting
### Deployment & DevOps
- **Dockerized Backend & Web** using **Docker Compose** for easy deployment
- **Makefile** to consolidate commands
### Frontend
- Built with **SvelteKit** and **Vite** for modern UI development
- Uses **Bootstrap** for responsive design and styling
### Backend
- Secure and scalable **Node.js & Express.js** architecture
- **Joi Middleware** for request validation and data integrity
- API documentation with **Swagger**
- **Retry Mechanism** to handle API failures gracefully
- **Rate limiting, CORS, Helmet, and Joi validation** for security and performance
- Proper test cases with **node:test**
## More commands
```bash
make lint-backend
```
Lint and Format the Backend Code.
Fixes ESLint errors in the backend code (backend/**/*.js).
Formats code using Prettier for consistent styling.
```bash
make start-backend
```
Starts the Backend. Navigates to the backend directory and starts the Node.js Express server.
Runs on port 7004 by default.
```bash
make start-web
```
Start the Frontend. Navigates to the web directory and starts the SvelteKit frontend.
Runs the frontend on port 5173 by default.
```bash
make service
```
Start the Full Application with Docker. Runs the entire application using Docker Compose.
```bash
make service-build
```
Builds all Docker containers without starting them. Useful if you want to prepare images before deployment.
```bash
make service-stop
```
Stops all running Docker containers gracefully.
```bash
make test
```
Start running the backed test cases.