Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Remove sidebar repeatedly
- setInterval(function() {
- const sidebar = document.querySelector('#watch7-sidebar')
- if (sidebar && sidebar.remove) sidebar.remove()
- const sidebarModules = document.querySelector('#watch7-sidebar-modules')
- if (sidebarModules && sidebarModules.remove) sidebarModules.remove()
- console.log('test')
- }, 500)
- // Remove player after it has been stopped
- const id = setInterval(function() {
- const hasStopped = !!document.querySelector('.ytp-play-button').title
- if (hasStopped) {
- clearInterval(id)
- location.replace('about:blank')
- }
- }, 200)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement