Skip to content

Instantly share code, notes, and snippets.

@NoahKamara
Forked from MRuy/pipeverywhere.user.js
Created May 29, 2022 00:26
Show Gist options
  • Save NoahKamara/25ec4f4bee79d85682524e81e32b782d to your computer and use it in GitHub Desktop.
Save NoahKamara/25ec4f4bee79d85682524e81e32b782d to your computer and use it in GitHub Desktop.
Userscript: PiP everywhere
// ==UserScript==
// @name PictureInPicture
// @namespace pip
// @version 1.0.0
// @description PiP everywhere
// @author You
// @include *
// @grant GM_registerMenuCommand
// ==/UserScript==
GM_registerMenuCommand('Video popout', pip);
function pip() {
document.querySelector('video').requestPictureInPicture();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment