How to use the derby.logPlugin function in derby

To help you get started, we’ve selected a few derby examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github triptec / derby-learn-by-example / lib / server / index.js View on Github external
var http = require('http')
  , path = require('path')
  , express = require('express')
  , gzippo = require('gzippo')
  , derby = require('derby')
  , auth = require('derby-auth')
  , app = require('../app')
  , serverError = require('./serverError')


// SERVER CONFIGURATION //

var expressApp = express()
  , server = module.exports = http.createServer(expressApp)

derby.use(derby.logPlugin)
derby.use(require('racer-db-mongo')); // This line is new

var store = derby.createStore({
  listen: server,
  db:      {type: 'Mongo', uri: process.env.MONGOHQ_URL || 'mongodb://localhost/snippets'}
})

//Authentication
auth.store(store);

var options, strategies;
strategies = {
  facebook: {
    strategy: require("passport-facebook").Strategy,
    conf: {
      clientID: process.env.FACEBOOK_KEY,

derby

MVC framework making it easy to write realtime, collaborative applications that run in both Node.js and browsers.

MIT
Latest version published 3 days ago

Package Health Score

79 / 100
Full package analysis