Questions tagged «ecmascript-2017»

20
සෑම ලූපයක් සමඟම අසින්ක් / බලා සිටීම
භාවිතා ඕනෑම ගැටලූ පවතින async/ awaitදී forEachපුඩුවක්? මම ලිපිගොනු සමූහයක් හරහා සහ awaitඑක් එක් ගොනුවේ අන්තර්ගතය මත ලූප කිරීමට උත්සාහ කරමි . import fs from 'fs-promise' async function printFiles () { const files = await getFilePaths() // Assume this works fine files.forEach(async (file) => { const contents = await fs.readFile(file, …
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.