Allow arena to work as a node module alongside auth middleware.#123
Closed
aaron-blondeau-dose wants to merge 1 commit intobee-queue:masterfrom
orchard-insights:master
Closed
Allow arena to work as a node module alongside auth middleware.#123aaron-blondeau-dose wants to merge 1 commit intobee-queue:masterfrom orchard-insights:master
aaron-blondeau-dose wants to merge 1 commit intobee-queue:masterfrom
orchard-insights:master
Conversation
…ddleware is needed.
|
I'm looking forward to this |
elsbree
reviewed
Feb 14, 2019
|
|
||
| app.use(app.locals.appBasePath, express.static(path.join(__dirname, 'public'))); | ||
| app.use(app.locals.appBasePath, routes); | ||
| app.locals.mountPath = listenOpts.mountPath || app.locals.basePath; |
There was a problem hiding this comment.
Unless I'm reading this incorrectly, you intended for this to be listenOpts.mountPath || app.locals.appBasePath;, right?
|
Any updates on this? |
Contributor
|
I have no idea why it is not merged yet. |
skeggse
requested changes
Aug 5, 2020
Member
skeggse
left a comment
There was a problem hiding this comment.
This has been a long-requested feature. I'd like to move this along, but still don't have a ton of time to review. I don't immediately understand the distinction between the appBasePath and the mountPath. Along those lines, could we get some documentation in the readme describing how the new option functions and how it differs from the old?
Member
|
Merging #182 into this. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I have been unable to find a way to add arena to an existing express app while also implementing authentication. The basePath parameter conflicts with any path other than "/" provided to express' use method. Allowing users to provide a new parameter called "mountPath" can alleviate this issue and allow configs like the following to work:
where basicAuth = https://github.com/expressjs/basic-auth-connect