Skip to content

Instantly share code, notes, and snippets.

@judell
Last active February 18, 2018 20:50
Show Gist options
  • Save judell/4e074a239ac3aacdeb3d to your computer and use it in GitHub Desktop.
Save judell/4e074a239ac3aacdeb3d to your computer and use it in GitHub Desktop.
h bookmarklet to auto-open frame
//javascript:(function(){window.hypothesisConfig=function(){return{showHighlights:true};};var d=document,s=d.createElement('script');s.setAttribute('src','https://hypothes.is/app/embed.js');d.body.appendChild(s);var timer = setInterval(function(){if (window.annotator){window.annotator.showFrame();clearInterval(timer);}},300;})();
javascript: (function() {
window.hypothesisConfig = function() {
return {
showHighlights: true
};
};
var d = document,
s = d.createElement('script');
s.setAttribute('src', 'https://hypothes.is/app/embed.js');
d.body.appendChild(s);
var timer = setInterval(function(){
if (window.annotator) {
window.annotator.showFrame();
clearInterval(timer);
}
},300);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment