-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lint #6555
Conversation
@@ -10,7 +10,6 @@ import onAbort from './helpers/abort-controller'; | |||
import ArrayMap from './helpers/map-of-arrays'; | |||
import bisectFeatures from './helpers/bisect'; | |||
import {shouldFeatureRun} from './github-helpers'; | |||
import polyfillTurboEvents from './github-helpers/turbo-events-polyfill'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PJAX is old news
@@ -38,12 +38,12 @@ function initRepoList(signal: AbortSignal): void { | |||
} | |||
|
|||
void features.add(import.meta.url, { | |||
include: [ | |||
pageDetect.hasRepoHeader, | |||
], | |||
asLongAs: [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
asLongAs
must be first
@@ -55,5 +57,5 @@ export default function observe< | |||
signal?.addEventListener('abort', () => { | |||
rule.remove(); | |||
}); | |||
window.addEventListener('animationstart', getListener(seenMark, selector, listener), {signal}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This lets us listen to the feature unload inside the observer’s callback:
function add(element, {signal}) {
wrap(element, <strong/>)
signal.addEventListener('abort', () => {
element.remove();
});
}
function init(signal) {
observe('a', add, {signal})
}
Mentioned in:
No description provided.