express-routes-mapper
Advanced tools
Comparing version 0.0.9 to 0.0.10
@@ -1,1 +0,1 @@ | ||
"use strict";function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function mapRoutes(e){var r=void 0,t=void 0,o=void 0,u=void 0,s=void 0,i=void 0,p=void 0;for(var l in e)if(e.hasOwnProperty(l)){r=l.replace(/\s\s+/g," "),t=r.split(" ")[0].toLocaleLowerCase(),o=r.split(" ")[1],s=e[l].split(".")[0],u=e[l].split(".")[1];try{i=require("../../../app/controllers/"+s).default,p=new i}catch(e){i=require("../../../app/controllers/"+s),p=i}"get"==t?router.route(o).get(p[u]):"post"==t?router.route(o).post(p[u]):"put"==t?router.route(o).put(p[u]):"delete"==t&&router.route(o).delete(p[u])}return router}require("babel-register");var _express=require("express"),_express2=_interopRequireDefault(_express),router=_express2.default.Router();module.exports=mapRoutes; | ||
"use strict";function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function mapRoutes(e){var r=void 0,t=void 0,o=void 0,u=void 0,s=void 0,i=void 0,p=void 0;for(var l in e)if(e.hasOwnProperty(l)){r=l.replace(/\s\s+/g," "),t=r.split(" ")[0].toLocaleLowerCase(),o=r.split(" ")[1],s=e[l].split(".")[0],u=e[l].split(".")[1];try{require("babel-register"),i=require("../../../app/controllers/"+s).default,p=new i}catch(e){i=require("../../../app/controllers/"+s),p=i}"get"==t?router.route(o).get(p[u]):"post"==t?router.route(o).post(p[u]):"put"==t?router.route(o).put(p[u]):"delete"==t&&router.route(o).delete(p[u])}return router}var _express=require("express"),_express2=_interopRequireDefault(_express),router=_express2.default.Router();module.exports=mapRoutes; |
{ | ||
"name": "express-routes-mapper", | ||
"version": "0.0.9", | ||
"version": "0.0.10", | ||
"description": "a small mapper for express routes", | ||
"main": "./dist/index.js", | ||
"scripts": { | ||
"test": "" | ||
"test": "", | ||
"prepublish": "gulp" | ||
}, | ||
@@ -9,0 +10,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7486