0
當我運行以下內容時,我立即在指定的覆蓋文本的區域中看到「Five」。 (我預計會看到「一」,然後「兩」等)我錯過了什麼?Popcorn.js設置多個提示()
document.addEventListener("DOMContentLoaded", function() {
putHere = document.getElementById("putHere");
pop = Popcorn("#side1"); // Create a popcorn instance
var states = function() {
var rdy = pop.readyState();
if (rdy !== 4) setTimeout(states, 10);
else {
pop.cue(12, layover("One"));
pop.cue(168, layover("Two"));
pop.cue(336, layover("Three"));
pop.cue(506, layover("Four"));
pop.cue(703, layover("Five"));
}
}
states();
}, false);