We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Express 4.x provides a new instance Route which can have a middleware stack of it's own. I suggest using baby-loris-api like so:
var express = require('express'); var bodyParser = require('body-parser'); var apiMiddleware = require('baby-loris-api/lib/middleware'); var apiRouter = express.Router(); apiRouter .use(bodyParser.urlencoded({extended: false})) .use('/:method?', apiMiddleware('/home/dodev/source/metro/api/**/*.api.js')); var app = express(); app .use('/api', apiRouter);
That way the middleware for the api won't be executed for the main part of the application.
The text was updated successfully, but these errors were encountered:
Add more examples. fixed #11, fixed #6
022f255
98d510d
d6a1920
No branches or pull requests
Express 4.x provides a new instance Route which can have a middleware stack of it's own. I suggest using baby-loris-api like so:
That way the middleware for the api won't be executed for the main part of the application.
The text was updated successfully, but these errors were encountered: