pouchdb / pouchdb-fauxton

Fork of CouchDB Fauxton for PouchDB Server
Apache License 2.0
6 stars 7 forks source link

Update build task. Serve Fauxton at express-pouchdb, expect server there... #4

Closed MichaelJCole closed 9 years ago

MichaelJCole commented 9 years ago

... as well.

Hey, this is a partial fix for: https://github.com/pouchdb/express-pouchdb/issues/116

Example server:

var port = 3001;

var express = require('express')
  , app     = express()
  , PouchDB = require('pouchdb')
  , logger  = require('morgan')
  ;

app.use(logger("tiny"));

app.get('/', function(req, res) {
  res.type('text/plain');
  res.send('i am a beautiful butterfly');
});

app.use('/express-pouchdb', require('express-pouchdb')(PouchDB));

console.log('listening on port ' + port);
app.listen(port);
MichaelJCole commented 9 years ago

This PR is improved by the next.