tiny-server-essentials
Version:
A good utility toolkit to unify Express v5 and Socket.IO v4 into a seamless development experience with modular helpers, server wrappers, and WebSocket tools.
104 lines (68 loc) β’ 4.48 kB
Markdown
<div align="center">
<p>
<a href="https://discord.gg/TgHdvJd"><img src="https://img.shields.io/discord/413193536188579841?color=7289da&logo=discord&logoColor=white" alt="Discord server" /></a>
<a href="https://www.npmjs.com/package/tiny-server-essentials"><img src="https://img.shields.io/npm/v/tiny-server-essentials.svg?maxAge=3600" alt="NPM version" /></a>
<a href="https://www.npmjs.com/package/tiny-server-essentials"><img src="https://img.shields.io/npm/dt/tiny-server-essentials.svg?maxAge=3600" alt="NPM downloads" /></a>
</p>
<p>
<a href="https://www.patreon.com/JasminDreasond"><img src="https://img.shields.io/badge/donate-patreon-F96854.svg?logo=patreon" alt="Patreon" /></a>
<a href="https://ko-fi.com/jasmindreasond"><img src="https://img.shields.io/badge/donate-ko%20fi-29ABE0.svg?logo=ko-fi" alt="Ko-Fi" /></a>
<a href="https://chain.so/address/BTC/bc1qnk7upe44xrsll2tjhy5msg32zpnqxvyysyje2g"><img src="https://img.shields.io/badge/donate-bitcoin-F7931A.svg?logo=bitcoin" alt="Bitcoin" /></a>
<a href="https://chain.so/address/LTC/ltc1qchk520v4u8334n5dntmgeja55gc5g5rrkgpd4f"><img src="https://img.shields.io/badge/donate-litecoin-345D9D.svg?logo=litecoin" alt="Litecoin" /></a>
</p>
<p>
<a href="https://nodei.co/npm/tiny-server-essentials/"><img src="https://nodei.co/npm/tiny-server-essentials.png?downloads=true&stars=true" alt="npm installnfo" /></a>
</p>
</div>
# π Tiny Server Essentials
**A modular and strict toolkit for building scalable Express v5 + Socket.IO v4 apps with ease.**
## π§ What is this?
This project is a **collection of reusable server-side modules** designed to simplify and improve how you build modern real-time applications using:
* β
**Express v5** (modern middleware chaining)
* π **Socket.IO v4** (reliable WebSocket communication)
* π§© **Strict helpers** and **validation tools** to interconnect both layers with minimal effort
Instead of creating everything from scratch, this toolkit provides **well-structured classes and utilities** that speed up development while promoting clarity and separation of concerns.
## π What can it do?
With this toolkit, you can:
* βοΈ Manage a single unified HTTP(S) server for both REST and WebSockets
* π Register and validate domain names for secure multi-tenant setups
* π§Ύ Normalize, extract and match IP addresses with fallback strategies
* π‘ Simplify bi-directional communication logic using Socket.IO over a clean `TinyIo` wrapper
* π§ͺ See it all in action with fully working examples
## ποΈ Where is everything?
You can find detailed documentation about each module in the [docs overview](./docs), where all core components like Express, Instance, Io, and Utils are explained clearly.
Also see [`/docs/client`](./docs/client) for browser-related features like ποΈ mic volume filters!
## π§ͺ Test It Yourself!
Looking for real use cases? Check out the [`test/servers`](./test/servers) folder for **simple and working examples** of how to:
* π§΅ Combine Express and Socket.IO on the same port
* π§© Integrate all modules for production-style setups
* π Test domain validation, IP filters, and WebSocket events
Just clone, install, and run a test server to see the magic in action! β¨
## π οΈ Tech Stack
* **Node.js** (18+ recommended)
* **Express v5**
* **Socket.IO v4**
## π€ Contributions
Feel free to fork, contribute, and create pull requests for improvements! Whether it's a bug fix or an additional feature, contributions are always welcome.
## π License
This project is licensed under the GPL-3.0 License - see the [LICENSE](LICENSE) file for details.
## π‘ Credits
> π§ **Note**: This documentation was written by [ChatGPT](https://openai.com/chatgpt), an AI assistant developed by OpenAI, based on the project structure and descriptions provided by the repository author.
> If you find any inaccuracies or need improvements, feel free to contribute or open an issue!
## π Back to Tiny Essentials
Did you like this module? Itβs part of the **Tiny Essentials** collection β a set of minimal yet powerful tools to make development easier.
π [Click here to explore more Tiny Essentials modules](https://github.com/JasminDreasond/Tiny-Essentials)
<div align="center">
<a href="./md-assets/img/"><img src="./md-assets/img/6c2df338-5257-4a2d-9dea-14f9f4ae8aba.png" height="300" /></a>
<br/>
Made with tiny love!
</div>