Saw that https://runkit.com/docs/await
shows how to use await inside RunKit directly.
This work currently because nodejs wrap the module in a function call. But it may not work in the future.
Some good read about this topic: https://gist.github.com/Rich-Harris/0b6f317657f5167663b493c722647221
me1000
March 22, 2017, 6:25pm
2
Hi Unional,
With RunKit we actually do our own transforms on user code, so top level awaits will always work in RunKit (unless of course we change it).
Thanks,
-Randy
The examples at https://runkit.com/docs/await do not works anymore, I get Error: Cannot find module 'is-retry-allowed'
exception when I try to run await example.
This is fixed now, sorry for the issues!
Thanks,
Francisco