New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

nodeboilerplate

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nodeboilerplate - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

boilerplate/.npmignore

4

boilerplate/app.js

@@ -5,7 +5,11 @@ var express = require('express'),

// Load express configuration
require(__dirname + '/config/env.js')(express, app);
// Load routes
require(__dirname + '/routes')(app);
// Start the server
app.listen(opts.port);
console.log("Express server listening on port %d in %s mode",
app.address().port, app.settings.env);

@@ -0,13 +1,27 @@

var util = require(__dirname + '/../libs/util.js');
module.exports = function (express, app) {
// Common configuration
app.configure(function () {
// Configure jQuery template engine
app.set('views', __dirname + '/../views');
app.set('view engine', 'jqtpl');
app.register('.jqtpl', require('jqtpl').express);
app.use(express.compiler({
// Make sure build folders exist
util.mkdir(__dirname + '/../build');
util.mkdir(__dirname + '/../build/css');
// Configure LESS compiler
app.use('/css', express.compiler({
enable: ['less'],
src: __dirname + '/../src/',
dest: __dirname + '/../build/'
src: __dirname + '/../src/less',
dest: __dirname + '/../build/css'
}));
app.use(app.router);
// Create static file servers for the build and public folders
app.use(express.static(__dirname + '/../build'));

@@ -17,2 +31,3 @@ app.use(express.static(__dirname + '/../public'));

// Development specific configuration
app.configure('development', function () {

@@ -25,2 +40,3 @@ app.use(express.errorHandler({

// Production specific configuration
app.configure('production', function () {

@@ -27,0 +43,0 @@ app.use(express.errorHandler());

11

boilerplate/config/opts.js

@@ -0,6 +1,7 @@

// Argument parsing using the optimist module
module.exports = require('optimist')
.usage('Usage: $0 --port [port]')
.alias('port', 'p')
.describe('port', 'Port number for the Express application.')
.default('port', 3000)
.argv;
.usage('Usage: $0 --port [port]')
.alias('port', 'p')
.describe('port', 'Port number for the Express application.')
.default('port', 3000)
.argv;

@@ -6,3 +6,3 @@ module.exports = function (app) {

var index = function (req, res) {
res.render('index', { title: 'Node Boilerplate' });
res.render('index', { title: 'Node Boilerplate' });
};
{
"name": "nodeboilerplate",
"description": "Boilerplate Node Application",
"version": "0.0.1",
"version": "0.0.2",
"author": "Brian Stone",

@@ -6,0 +6,0 @@ "keywords": ["boilerplate", "nodeboilerplate", "template"],

@@ -22,2 +22,7 @@ Node Boilerplate

Documentation
-------------
[Annotated Source](http://stonebk.github.com/nodeboilerplate/)
Configuration

@@ -24,0 +29,0 @@ -------------

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc