| Crates.io | koiweb-framework |
| lib.rs | koiweb-framework |
| version | 0.1.0 |
| created_at | 2025-12-06 13:01:05.367839+00 |
| updated_at | 2025-12-06 13:01:05.367839+00 |
| description | A micro web framework for Rust, inspired by Express.js. Just for trying or study, not for production. |
| homepage | |
| repository | https://github.com/KhaiNguyenHoang/koiweb-framework |
| max_upload_size | |
| id | 1970128 |
| size | 59,976 |
Koiweb is a micro web framework for Rust, inspired by Express.js. It aims to provide a simple, flexible, and performant way to build web applications.
src/lib.rs: Contains the core framework logic (App, Router, Request, Response, Middleware, etc.).src/main.rs: An example application demonstrating how to use the framework.public/: Directory for serving static files (currently not implemented, but a planned feature).uploads/: Directory where uploaded files are stored.Clone the repository:
git clone https://github.com/KhaiNguyenHoang/koiweb-framework.git
cd koiweb-framework
Run the example application:
cargo run
The server will start on http://127.0.0.1:8080 (or the port specified by the PORT environment variable).
GET /users/123
Returns a JSON object: {"user_id": "123"}uploads/ directory. Files are limited to 10MB.
Example using curl:
curl -X POST -H "Content-Type: application/octet-stream" --data-binary "@your_file.txt" http://127.0.0.1:8080/upload
{"status": "ok"}The server's listening port can be configured using the PORT environment variable. If not set, it defaults to 8080.
PORT=3000 cargo run
Contributions are welcome! Please open an issue or submit a pull request.
This project is licensed under the Apache 2.0.