Created
May 27, 2016 22:52
-
-
Save diorahman/7863148ea0b6d203f4bc8fd56f78c0bb to your computer and use it in GitHub Desktop.
This file contains 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
import { boot, send } from 'ysera'; | |
const delay = () => { | |
return new Promise((resolve) = > { | |
setTimeout(resolve, 1000); | |
}) | |
} | |
const fn = async (req, res) => { | |
await delay(); | |
send(res, 200, 'OK'); | |
}; | |
boot(fn, 3000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment