MCPcopy
hub / github.com/refined-github/refined-github / initOnce

Function initOnce

source/features/shorten-links.tsx:7–14  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5
6/* This feature is currently so broad that it's not de-inited via signal, it's just run once for all pageloads #5889 */
7function initOnce(): void {
8 observe([
9 `.comment-body a[href]:not(.${linkifiedUrlClass})`,
10 `.react-issue-comment .markdown-body a[href]:not(.${linkifiedUrlClass})`, // Issue comments
11 `.react-issue-body .markdown-body a[href]:not(.${linkifiedUrlClass})`, // First issue comment
12 `[data-testid="review-thread"] .markdown-body a[href]:not(.${linkifiedUrlClass})`, // React commit view
13 ], shortenLink);
14}
15
16void features.add(import.meta.url, {
17 init: onetime(initOnce),

Callers

nothing calls this directly

Calls 1

observeFunction · 0.85

Tested by

no test coverage detected