Modern Node router


Keywords
router, routex, node
License
MIT
Install
npm install routex@1.0.1

Documentation

Routex npm Travis CI Codecov Greenkeeper badge

Modern Node router.

Documentation - GitHub

Features

  • Easy to use, good performance
  • Modern API, native Promise support, fully typed (TypeScript)
  • Close compatibility with Express/Koa, fast migration
  • Very few dependencies, small API surface, easy to fully understand and extend
  • 100% code coverage, well tested

Example

Install:

yarn add routex
# or
npm add routex

Setup your app:

const { Routex, TextBody } = require("routex");

const port = process.env.PORT || 3000;
const app = new Routex();

app.get("/", ctx => {
  ctx.body = new TextBody("Hello world!");
});

app.listen(port).then(() => console.log(`Listening on ${port}`));

Support

We support all currently active and maintained Node LTS versions, include current Node versions.

Please file feature requests and bugs at the issue tracker.