[object Object]

← back to Port Viewer

add rel="noopener noreferrer" to external target="_blank" links

d93015a9a0c883367746c8f1f7f789de6b035744 · 2026-05-19 15:12:56 -0700 · Steve Abrams

Domain card "🔗" link and per-port website link both opened external URLs
in new tabs without rel — tab-nabbing risk closed.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

Files touched

Diff

commit d93015a9a0c883367746c8f1f7f789de6b035744
Author: Steve Abrams <steve@designerwallcoverings.com>
Date:   Tue May 19 15:12:56 2026 -0700

    add rel="noopener noreferrer" to external target="_blank" links
    
    Domain card "🔗" link and per-port website link both opened external URLs
    in new tabs without rel — tab-nabbing risk closed.
    
    Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---
 public/index.html | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/public/index.html b/public/index.html
index 23b39fb..ee5e02a 100644
--- a/public/index.html
+++ b/public/index.html
@@ -1891,7 +1891,7 @@
                             <div style="display: flex; align-items: center; gap: 12px;">
                                 <div class="domain-status"></div>
                                 <div class="domain-name">${domain}</div>
-                                <a href="https://${domain}" target="_blank" class="domain-link">🔗</a>
+                                <a href="https://${domain}" target="_blank" rel="noopener noreferrer" class="domain-link">🔗</a>
                             </div>
                             <div class="domain-iframe-container">
                                 <iframe class="domain-iframe" src="${proxyUrl}" sandbox="allow-same-origin allow-scripts allow-forms allow-popups"></iframe>
@@ -2197,7 +2197,7 @@
                                 ? `http://localhost:${port.port}`
                                 : `https://${website}`;
                             websiteLinksHTML += `
-                                <a href="${url}" class="website-link" target="_blank"
+                                <a href="${url}" class="website-link" target="_blank" rel="noopener noreferrer"
                                    onmouseover="showPreview('${url}', '${website}')"
                                    onmouseout="hidePreviewDelayed()">
                                     ${website} <span class="open-icon">↗</span>

← ee28ffe snapshot: 1 file(s) changed, ~1 modified  ·  back to Port Viewer  ·  broaden .gitignore to cover *.bak.* and *.pre-* snapshot pat a86bf08 →