express-forward
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -14,3 +14,2 @@ 'use strict'; | ||
var url = req.path.replace(regex, ''); | ||
console.log('URL', url); | ||
return Promise.resolve(req.pipe(request({ | ||
@@ -17,0 +16,0 @@ qs: req.query, |
@@ -1,2 +0,2 @@ | ||
"use strict";var e,r=(e=require("request"))&&"object"==typeof e&&"default"in e?e.default:e;exports.expressForward=function(e,t){var o=e.replace(/^\//,"");t.all("/"+o+"/*",function(e,t){try{try{var s=new RegExp("^/"+o+"/"),a=e.path.replace(s,"");return console.log("URL",a),Promise.resolve(e.pipe(r({qs:e.query,uri:a})).pipe(t))}catch(e){return Promise.resolve(t.json(e))}}catch(e){return Promise.reject(e)}})}; | ||
"use strict";var e,r=(e=require("request"))&&"object"==typeof e&&"default"in e?e.default:e;exports.expressForward=function(e,t){var s=e.replace(/^\//,"");t.all("/"+s+"/*",function(e,t){try{try{var a=new RegExp("^/"+s+"/"),o=e.path.replace(a,"");return Promise.resolve(e.pipe(r({qs:e.query,uri:o})).pipe(t))}catch(e){return Promise.resolve(t.json(e))}}catch(e){return Promise.reject(e)}})}; | ||
//# sourceMappingURL=express-forward.cjs.production.min.js.map |
@@ -10,3 +10,2 @@ import request from 'request'; | ||
var url = req.path.replace(regex, ''); | ||
console.log('URL', url); | ||
return Promise.resolve(req.pipe(request({ | ||
@@ -13,0 +12,0 @@ qs: req.query, |
{ | ||
"name": "express-forward", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"main": "dist/index.js", | ||
@@ -15,3 +15,5 @@ "module": "dist/express-forward.esm.js", | ||
}, | ||
"peerDependencies": {}, | ||
"peerDependencies": { | ||
"express": "^4.17.1" | ||
}, | ||
"husky": { | ||
@@ -42,5 +44,4 @@ "hooks": { | ||
"@types/request": "^2.48.2", | ||
"express": "^4.17.1", | ||
"request": "^2.88.0" | ||
} | ||
} |
<div align="center"> | ||
<img src="media/logo.png" title="logo" alt="logo" width="454"> | ||
<!-- <img src="media/logo.png" title="logo" alt="logo" width="454"> --> | ||
<h1>express forward</h1> | ||
@@ -11,2 +11,3 @@ <p> | ||
## Usage | ||
### | ||
@@ -13,0 +14,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
22
7489
57
- Removedexpress@^4.17.1