0.2.0 • Published 11 years ago

express-autoload v0.2.0

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

Express-autoload

Express autoload is a set of tools to configure an Express.js application. Create a config file, define the paths for your controllers, models and views and express-autoload will load your files, connect to the database, authenticate...

Requirements

  • Node.js >= v0.6.2

Installation

  • npm install express-autoload

Configuring

Create a config.js file and edit it to set your configuration properties such as database host, port, username, password, etc.

Using

var autoloadApp = require('express-autoload')
  , config = require('./config');

autoloadApp(config, function(err, app) {
    if(err) {
        console.log(err.stack || err);
        return;
    }
    
    app.server.listen(config.port, config.hostname, function() {
        console.log('Server started on port %s in %s mode',
                    app.server.address().port,
                    app.express.settings.env);
    });
});
0.2.0

11 years ago

0.1.11

11 years ago

0.1.10

11 years ago

0.1.8

11 years ago

0.1.7

11 years ago

0.1.6

11 years ago

0.1.5

11 years ago

0.1.4

11 years ago

0.1.3

11 years ago

0.1.2

11 years ago

0.1.1

11 years ago

0.1.0

11 years ago