👁 查看:example.mjs
路径:/home/boguraj1/public_html/jobsite/node_modules/fastq/example.mjs
大小:221 B · 修改:2022-11-21 20:08:48 · 权限:0644 · 可写
import { promise as queueAsPromised } from './queue.js'

/* eslint-disable */

const queue = queueAsPromised(worker, 1)

console.log('the result is', await queue.push(42))

async function worker (arg) {
  return 42 * 2
}