The function executed to verify a particular condition until it's passed
Optionaltimeout: numberThe duration in milliseconds until the task is aborted (defaults to 10 seconds)
OptionalcheckFrequency: numberThe frequency in milliseconds to check for an update (defaults to 100 milliseconds)
This asynchronous generic function checks for a validity of something via the checkCallback() until it's found or until the timer runs out. This method returns a Promise which the developper can use to await or use .then().catch().finally() principles.