source:
trip-planner-front/node_modules/piscina/test/fixtures/esm-async.mjs
Last change on this file was 6a3a178, checked in by , 3 years ago | |
---|---|
|
|
File size: 241 bytes |
Line | |
---|---|
1 | import util from 'util'; |
2 | const sleep = util.promisify(setTimeout); |
3 | |
4 | // eslint-disable-next-line no-eval |
5 | function handler (code) { return eval(code); } |
6 | |
7 | async function load () { |
8 | await sleep(100); |
9 | return handler; |
10 | } |
11 | |
12 | export default load(); |
Note:
See TracBrowser
for help on using the repository browser.