摘要:
For example we have current code: function add(a, b) { console.log(a, b) return a + b } function subtract(a, b) { console.log(a, b) return a - b } add 阅读全文
摘要:
The Promise.any() method accepts an array (or any other iterable) of promises as a parameter. It returns a Promise object that is fulfilled with the v 阅读全文
摘要:
The Promise.allSettled() method accepts an array (or any other iterable) of promises as a parameter. It returns a Promise object that is fulfilled wit 阅读全文
摘要:
In this post, we are going to see how to use 'fakeAsync' to test async code in Angular Context. fakeAsync using Zoom.js underhook, it detects all the 阅读全文
摘要:
In Javascript, there are two types of event loops for async tasks. First one, is well known one, for example, setTimeout, http request, click event wi 阅读全文
摘要:
In the computer world, use restricted resource you have to generate maximum benefit is what we always want to pursue. For now, suppose you are a domin 阅读全文
摘要:
For example, we have the source code: getVersison('3.4.5') function getVersion(versionString) { const versionRegex = /(\d)\.(\d)\.(\d+)/ const [, majo 阅读全文