Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Backport of the #993 follow-up. An explicit url sets host and path and beats the canonical, so the bench fixture's explicit /path url wins again and its snapshot reverts.
nuxt-schema-org passes a host with a trailing slash or base path plus a url under it. Deriving host from the url origin dropped both and changed every graph @id, so a url under the current host now sets only the path.
A raw prefix check missed a url that differs from the host only in case or a default port, and then dropped the host base path.
Decisions from review: the url property follows an explicit url or canonical exactly, query and trailing slash included. Page @id values follow it only when it sits under the site host, so a cross-domain canonical cannot move node identity. trailingSlash shapes only the url built from host and path. Home page and page type checks read the path, since the url may now carry a query or another host.
🤖 READY · 88/100
Selected findings run after merge and open separate pull requests. |
🔗 Linked issue
Backport of #993.
Merge after #992. Both edit the canonical branch in
packages/schema-org/src/plugin.ts, so once #992 lands this needsv2merged in.❓ Type of change
📚 Description
Same bug as main:
resolveMetarebuilturlfromhostandpath, so neither the page<link rel="canonical">nor an expliciturl(or the deprecatedcanonicalUrl) reachedWebPageurlor@id. The page url now comes from an expliciturl, then the canonical, thenhost+path, with the same decisions as #993: a cross-domain url changes onlyWebPage.urlwhile ids stay on the site host, query strings are kept, and an explicit url ignorestrailingSlash.ResolvedMetagainspath(already present at runtime) andidUrl. The plugin config is no longer pre-resolved, since that filled a defaulturlthat would outrank the canonical.Behaviour change
An explicit
urlor canonical with a query, a trailing slash that differs fromtrailingSlash, or another host now shows inWebPage.url.ResolvedMetagainsidUrl, and its type now declarespath. See #993.