1×
Become a member
to unlock all features

Level Up!

Access all courses & lessons on egghead today and lock-in your price for life.

Autoplay

    Serve a random static file with Express

    expressExpress

    In this lesson we will look at serving static files using the static helper provided by Express.

    We'll then use the file system module in Node to read the contents of our static directory, select a random file and send the path back to our client.