Skip to content

Instantly share code, notes, and snippets.

@jpriebe
Created October 28, 2021 13:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jpriebe/4a8fd2ce6c54db702a505b097e656262 to your computer and use it in GitHub Desktop.
Save jpriebe/4a8fd2ce6c54db702a505b097e656262 to your computer and use it in GitHub Desktop.
wiki.js script injection
<script>
window.onload = function() {
for (var links = document.links, i = 0, a; a = links[i]; i++) {
if (a.host !== location.host) {
a.target = '_blank';
}
}
};
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment