reactioncommerce / redoc

redoc - generate documentation from multiple project repos.
GNU General Public License v3.0
20 stars 11 forks source link

Defining ROOT_URL with a subfolder #17

Open marceloschmidt opened 8 years ago

marceloschmidt commented 8 years ago

We defined ROOT_URL as a subfolder (eg. http://localhost:3000/docs). If we didn't touch the code, it would just not work at all. Server would render correctly, but then client would re-render a blank page. Any thoughts on how to fix that? We went ahead and made a few changes to the code, so now it works on a subfolder, but it has it's drawbacks. First, we had to include a meta tag, and now all links have to be relative instead of absolute. Second, although clicking a menu link will open the right URL, if you inspect the link, you'll notice that it points to what would be an invalid location, i.e., without the /docs, and so search engine crawlers wouldn't be able to crawl our page. Do you have a walkthrough on how to run this on a subfolder? TIA

aaronjudd commented 8 years ago

The alias of the main repo could be changed I think, or we could just add a global for a prefix to the routes.