0.0.4 • Published 7 years ago

blaker v0.0.4

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

Blaker

A modern and usable web framework for Node.js.

const { start, getUrl, getQuery, match, json } = require('blaker');

function* mainHandler() {
    const { id } = yield match('GET', '/users/:id'); // if URL is not equal /users/:id then abort

    const url = yield getUrl(); // get current url
    const query = yield getQuery(); // get all query

    return json({ paramId: id, currentUrl: url, requestQuery: query });
}

start(mainHandler)(3000); // listen 3000
0.0.4

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago