Skip to main content
Deno 2 is finally here 🎉️
Learn more

Promethium

DeepScan grade Github license badge Maintenance badge

Zero dependency, tiny web framework with routing included.

Why would you use it?

  • 💪 Built on native, Deno’s TCP server (v. high performance).
    • ⮤ Up to 9x times faster than Oak framework!
  • 🗺️ Supports both static & dynamic routing.
  • ♻️ Uses default Request & Response structs which are part of fetch API (no extra abstraction).
  • 📦 Comes with optional support for quick rendering of json & jsx. Those modules won’t be loaded by default - you have to import helpers.ts file to use them.

Quick performance check

Click to see quick benchmark results!
Native Web Server Promethium Web Framework
https://raw.githubusercontent.com/Amatsagu/Promethium/master/.github/native_benchmark.png https://raw.githubusercontent.com/Amatsagu/Promethium/master/.github/Promethium_benchmark.png
Avg. 40.97K req/sec Avg. 40.56K req/sec

The code comes from https://github.com/denoland/deno_std/blob/main/http/bench.ts. Promethium version had the same code attached to “/” route.


Example usage

Example app usage

Contributing

  1. Fork it!
  2. Modify project to your like.
  3. Test it! deno test --allow-net --allow-read --unstable
  4. Create your feature branch: git checkout -b my-new-feature
  5. Commit your changes: git commit -am 'Add some feature'
  6. Push to the branch: git push origin my-new-feature
  7. Submit a pull request :D