Like serve-static but for individual files. Refactored and decoupled from express res.sendFile. Can be used standalone with router to support HTTP/2 protocol.
npm i -S serve-file
import Router from 'router'import serveFile from 'serve-file' const app = Router()app.use('/my-file.txt', serveFile('path/to/my-file.txt'))
Combine open-source packages with your private code and publish to a private registry behind the firewall. npm ♥ enterprise developers
how? learn more