0.0.5 • Published 11 years ago

express-subdomains v0.0.5

Weekly downloads
94
License
-
Repository
-
Last release
11 years ago

express-subdomains

Build Status

Subdomains are placed at the beginning of a route by default.

Example

var subdomains = require('express-subdomains')
    , express = require('express')
    , app = Express.createServer()

// example: api.example.com/user -> '/api/user'

subdomains
  .use('api')
  .use('other.vanity.domain')

app.use(subdomains.middleware)

app.get('/api/user' function (req, res, next) {
  // ..
})

app.listen()
    

Tests

npm install mocha -g and make test

Install

npm install express-subdomains

License

MIT

0.0.5

11 years ago

0.0.4

12 years ago

0.0.3

12 years ago