Ejecución del código de retraso Swift 5
let timer = 1
DispatchQueue.main.asyncAfter(deadline: .now() + timer) {
// code to execute after 1 second
}
Wicked Wolf
let timer = 1
DispatchQueue.main.asyncAfter(deadline: .now() + timer) {
// code to execute after 1 second
}