slimjim

A razor thin, lightning fast web framework for rest api's

Usage no npm install needed!

<script type="module">
  import slimjim from 'https://cdn.skypack.dev/slimjim';
</script>

README

SlimJim

A razor thin, lightning fast web framework for rest api's

Description

SlimJim is for when really only need the basics. It is meant for a very specific purpose and that purpose only; building microservice style rest api's.

Example

import {SlimJim} from "slimjim";

const server = new SlimJim();

server.get("/test/:thing", (req, done) => {
    done(null, {
        statusCode: 200,
        headers: {},
        body: req,
    });
});

server.post("/submit", (req, done) => {
   done(null, {
       statusCode: 200,
       headers: {Thing: "yay"},
       body: req.body.potato,
   });
});

server.start(8080, undefined, () => {
    console.log("Server started");
});

Features

  • Body parsing
  • Lightning fast speeds
  • Simple api

Caveats

  • Very early, and indev

Version History

v0.2.0

  • Complete rewrite for turbo-http

v0.1.3

  • Fix typings path

v0.1.2

  • Fix for dep

v0.1.1

  • Small performance optimizations
  • Clarified example

v0.1.0

  • Initial release