Created
April 6, 2018 16:45
-
-
Save jinwoo/bcb6e4ebe205cf823482ef659bb0b506 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for (const asset of ['/static/awesome.css', '/static/unicorn.png']) { | |
// stream is a ServerHttp2Stream. | |
stream.pushStream({':path': asset}, (err, pushStream) => { | |
if (err) throw err; | |
pushStream.respondWithFile(asset); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment