massgrave.dev/_site/links.js

5 lines
165 B
JavaScript
Raw Normal View History

2023-01-11 12:19:43 +01:00
(function() {
for (const link of document.getElementsByTagName('a')) {
if (/^(https?:)?\/\//.test(link.getAttribute('href'))) link.target = '_blank';
}
})();