Open beecomci opened 2 years ago
// AS-IS this.previewVideo.addEventListener('click', event => { this.previewPlayer.pause(); this.playVideo(true); }); // TO-BE this.previewPlayer.addEventListener('play', event => { this.previewVideo.addEventListener('click', event => { this.previewPlayer.pause(); this.playVideo(true); }); });
// AS-IS this.corePlayer.pause(); // TO-BE const playPromise = this.corePlayer.play(); if (playPromise !== undefined) { playPromise .then(() => { this.corePlayer.pause(); }) catch(error => { console.err(error); }) }
video Uncaught (in promise) 오류
Case 1
Case 2
참고