kodfire
kodfire

Reputation: 1783

selector_matches not working in speculationrules for prerendering

I'm using Chrome v124.

My html:

<div><a class="sidebar" href="https://example.com/somewhere/">Test selector_match exclusion</a></div>

My speculationrules:

<script type="speculationrules">{"prerender":[{"source":"document","where":{"and":[{"href_matches":"/*"},{"not":{"selector_matches":".sidebar"}}]},"eagerness":"moderate"}]}</script>

but it doesn't exclude the link with the class of .sidebar when I hover over it.

prerender-1

prerender-2

Upvotes: 0

Views: 21

Answers (0)

Related Questions