node package manager


SPM middleware for debug.

Serve SPM

Middleware for spm debug, support connect, express and koa.

with express:

var serveSPM = require('serve-spm');
require('express')().use(serveSPM(pkgRoot, {
  log: true

with koa:

var serveSPM = require('serve-spm').koa;
require('koa')().use(serveSPM(pkgRoot, {
  log: true

Enable log for requests, default false.

Map pathname for debug. e.g. paths: [['/a/b/c/', '']]

Enable 304 cache.

Set seajs's base.

Copyright (c) 2014 sorrycc. Licensed under the MIT license.