I have a problem with the setAttribute
function.
Here my code
mind.SetRequest(rec_input.value);
mind.Reply();
element.setAttribute('text', mind.GetReply());
element.speak();
element.speak()
isn't waiting for setAttribute
to be completed.
Is there any function to call speak()
when setAttribute
is finished?
The img.onload = function(){ . . . }
function called after the img
is loaded, is there a similar way where I can call my speak
function after setAttribute
?