List All Routes in express app
Problem
Hi! I've been fighting this for a bit, but I'm trying to gather a list of all of the endpoints in our express applications. I've tried 'express-list-router' and the code below, but none give the full paths of the endpoint and the allowed methods to use them. I've read the documentation, but can't seem to find the properties/methods to access this information. Thank you in advance for your time and assistance!
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Solution: List All Routes in express app
Here is a very, very hacky way for that app. I can't stress how hacky this is, but here it is: [code block] That produces: [code block]
Trust Score
10 verifications
- 1
Here is a very, very hacky way for that app. I can't stress how hacky this is, b
[code block]
Validation
Resolved in expressjs/express GitHub issue #3308. Community reactions: 150 upvotes.
Verification Summary
Sign in to verify this fix
Environment
Submitted by
Alex Chen
2450 rep