Proposal
Add a user preference that makes external links (post URLs to non-reddit/non-lurker domains, oembed iframes, expanded ExtLinks) open in a new tab via target="_blank" rel="noopener noreferrer". Internal navigation (subreddit pages, comment threads, dashboard) stays in the same tab.
Definition of "external"
Any URL whose host is not the lurker host itself and not reddit.com / redd.it (those get rewritten to relative URLs by #34).
Schema
New column pref_openExternalInNewTab (boolean, default 0).
Touches
Acceptance
With the preference enabled, clicking an external post link opens a new tab; clicking a subreddit name or comment thread stays in the same tab.
Proposal
Add a user preference that makes external links (post URLs to non-reddit/non-lurker domains, oembed iframes, expanded ExtLinks) open in a new tab via
target="_blank" rel="noopener noreferrer". Internal navigation (subreddit pages, comment threads, dashboard) stays in the same tab.Definition of "external"
Any URL whose host is not the lurker host itself and not
reddit.com/redd.it(those get rewritten to relative URLs by #34).Schema
New column
pref_openExternalInNewTab(boolean, default 0).Touches
src/db.jsprefToColumnmap insrc/routes/index.js:566-571get_user_prefshelper atsrc/routes/index.js:952src/views/dashboard.pugtargetattribute on external anchors inpost.pug,comment.pug,index.pug— easiest via a pug mixin or utility helperAcceptance
With the preference enabled, clicking an external post link opens a new tab; clicking a subreddit name or comment thread stays in the same tab.