0.3.2 • Published 1 year ago

pathless v0.3.2

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Pathless

A lightweight, flexible routing library for JavaScript. Designed for simplicity, Pathless provides an intuitive API for handling HTTP requests and organizing your routes.

// CJS
const pathless = require("pathless");
// ESM
import pathless from "pathless";

const app = pathless();

app.get("/", (req, res) => res.send("Hello world!"));

app.listen(3000, () => console.log("Server is listening on port 3000"));

Features

  • Flexible Routing: Easily define routes for various HTTP methods, including support for dynamic and wildcard routes.
  • Middleware Support: Add global or route-specific middleware to handle tasks like authentication, logging, and more.
  • Modular Routers: Organize your application into reusable routers for better scalability and maintainability.

Quick Start

$ npm i pathless@latest
$ yarn add pathless@latest
$ pnpm i pathless@latest

Comparison with other frameworks

StatFramework1%2.5%50%97.5%AvgStdevMin
Req/SecPathless27,21527,21532,44733,98331,973.821,827.8727,214
Express6,4516,4518,2798,4958,023.82609.146,451
Hono28,07928,07934,39935,32733,888.731,882.3928,065

(from frolleks/nodejs-http-framework-benchmark)

Documentation

Visit the repository's Wiki.

License

MIT License

0.3.2

1 year ago

0.3.1

1 year ago

0.3.0

1 year ago

0.2.1

1 year ago

0.2.0

1 year ago

0.1.0

1 year ago

0.0.8

1 year ago

0.0.7

1 year ago

0.0.6

1 year ago

0.0.5

1 year ago

0.0.4

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago