Node repl with async await

前端 未结 3 2077
夕颜
夕颜 2021-02-07 00:36

I would like to add support to async/await to node repl

Following this issue: https://github.com/nodejs/node/issues/8382

I\'ve tried to use this one https://gith

3条回答
  •  -上瘾入骨i
    2021-02-07 01:12

    As of node ^10, you can use the following flag when starting the repl:

    node --experimental-repl-await
    $ await myPromise()
    

提交回复
热议问题