How to use promise-all-props - 1 common examples

To help you get started, we’ve selected a few promise-all-props examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github autonomoussoftware / metronome-wallet-desktop / src / services / auction.js View on Github external
auction.getStatus = function() {
  const token = mtn.mtntoken.methods
  const auctions = mtn.auctions.methods

  return promiseAllProps({
    currentAuction: auctions.currentAuction().call(),
    currentPrice: auctions.currentPrice().call(),
    genesisTime: auctions
      .genesisTime()
      .call()
      .then(toInt),
    globalMtnSupply: auctions.globalMtnSupply().call(),
    lastPurchasePrice: auctions.lastPurchasePrice().call(),
    lastPurchaseTick: auctions
      .lastPurchaseTick()
      .call()
      .then(toInt),
    mintable: auctions.mintable().call(),
    nextAuction: auctions.nextAuction().call(),
    totalSupply: token.totalSupply().call()
  })

promise-all-props

Like `Promise.all` but for object properties.

ISC
Latest version published 9 months ago

Package Health Score

53 / 100
Full package analysis

Popular promise-all-props functions