paint-brush
Routing Life Hacks: Serving a Node.js Express App from a Sub-Folderby@olekon86
5,280 reads
5,280 reads

Routing Life Hacks: Serving a Node.js Express App from a Sub-Folder

by Oleg2mAugust 31st, 2019
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

Express is probably the most popular web framework for Node.js and tons of tutorials and instructions have already been written. However, most of them don't cover the topic I am going to tell you about. A standard approach to routing that is seen across various docs looks like this: or this: "Routing structure probably looks somewhat similar to the picture below," but in real-world there might be a small problem. An actual catalogue for your application on hosting platform might be other than the domain root.
featured image - Routing Life Hacks: Serving a Node.js Express App from a Sub-Folder
Oleg HackerNoon profile picture
Oleg

Oleg

@olekon86

Software developer, Ethereum and beyond

About @olekon86
LEARN MORE ABOUT @OLEKON86'S
EXPERTISE AND PLACE ON THE INTERNET.
L O A D I N G
. . . comments & more!

About Author

Oleg HackerNoon profile picture
Oleg@olekon86
Software developer, Ethereum and beyond

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite
Also published here