how to delay something with promise all code example Example: js add delay with promises await new Promise(resolve => setTimeout(resolve, 1000));