npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

leaf-koala

v1.0.0

Published

Koa Framework Suite

Downloads

3

Readme

Koalaα

NPM version Build status Test coverage Dependency Status License Downloads

A suite of Koa utilities allowing for quicker bootstrapping, as well as a consequential guide on how to write apps using the Koa philosophy. Think of it as a KrakenJS for Koa.

Beware! Koala is alpha software!

Philosophy

Koa is a bare minimal framework, focusing on unopinionated core HTTP utilities. However, this is not sufficient for most apps as a lot is not supported out of the box. Including a bunch of dependencies in every new app you create quickly becomes annoying.

The goal of Koala is to include the most used and unopinionated parts of apps into a single framework. Many things such as body parsing, sessions, and CSRF are included. Many other things, such as routing, is too opinionated and not included.

Unlike other frameworks, Koala will not dictate how to write business logic. Thanks to generators and, eventually, ES7 Async/Await, writing business logic in Koa is much easier than other frameworks, and Koala's goal is to only make it easier. Don't expect a single option to automatically do magic for your app.

Feel free to create suggestions!

Features and Documentation

The Koala framework adds to Koa:

  • Body Parsing
    • Seamless Expect: 100-continue support
    • Per-request body limits
    • Supports JSON, urlencoded, and multipart bodies
    • Supports arbitrary strings, buffers, and files as bodies
    • Optional nested parameter support
  • SPDY - specifically push streams
  • File Serving - with SPDY push support
  • Sessions
    • Cookie-based sessions
    • CSRF protection
  • Response Caching - cache and serve responses using an arbitrary store
  • JSONP - safe jsonp support
  • Security Headers
  • Error Page - better default error page
  • Tracing
  • etc
    • Basic auth
    • Object stream support
    • Optional nested query string supported
  • FAQ

koala(1) will be a generator, similar to what express(1) is.

Usage

Simply replace require('koa') with require('koala'). Koala returns a koa app, except it includes more features.

var koala = require('koala');
var app = koala();

app.use(function* () {
  this.response.status = 204;
});

var fn = app.callback();

require('http').createServer(fn).listen(function (err) {
  if (err) throw err;
  console.log('Koala app listening on port %s', this.address().port);
});

Roadmap

Some additional features may include:

  • Timeout assertion
  • Server-Side Event Streams
  • Rate limiting

Let me know if you have any other suggestions.