Putting simplified version of 'resolve' in routes.json and modifying .eslintrc to create a convention that any variable matching ^_ (starts with _) will be excempt from the variable used check.

This commit is contained in:
Colby Gutierrez-Kraybill 2015-09-14 13:36:00 -04:00
parent 2e1cd7b7d7
commit 4b6cc3dfa2
3 changed files with 4 additions and 2 deletions

View file

@ -7,7 +7,8 @@
"linebreak-style": [2, "unix"],
"max-len": [2, 120, 4],
"semi": [2, "always"],
"strict": [2, "never"]
"strict": [2, "never"],
"no-unused-vars": [2, {"args": "after-used", "varsIgnorePattern": "^_"}]
},
"env": {
"browser": true,

View file

@ -1,5 +1,6 @@
var compression = require('compression');
var express = require('express');
var _path = require('path');
var handler = require('./handler');
var log = require('./log');

View file

@ -17,7 +17,7 @@
},
{
"static": true,
"resolve": "(function(){ var path = require('path'); return(path.resolve(__dirname, '../build'));})()",
"resolve": "_path.resolve(__dirname, '../build')",
"attributes": { "lastModified": true, "maxAge": "1y" },
"_todo": " TODO: Define a specification for how each entry is used/expected to look like, given the nginx conf generator's needs and stand-alone run-time needs. An outline of this so far: static requires resolve/attributes but could use pattern too. ..."
}