Skip to content

Fix the markets recipe doc links and the Deleted Files links - #4291

Merged
lucyxiang merged 1 commit into
2026-04from
lucy/markets-recipe-commit
Nov 2, 2026
Merged

lucyxiang merged 1 commit into
2026-04from
lucy/markets-recipe-commit

Conversation

@lucyxiang

@lucyxiang lucyxiang commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

TL;DR: Some links in the cookbook docs return 404. The markets links to the new sanitizeHtml.ts point to a commit that is older than the file, and every "Deleted Files" link has templates/skeleton/ twice. This PR fixes both.

The rendered README and LLM prompt build every file link from the commit field in recipe.yaml. For markets, that field was 1040066d, which is older than #4278. The shopify.dev page uses the same links.

Before

commit: 1040066d20b52667756fd1ebffd8607602a735b4
  • https://github.com/Shopify/hydrogen/blob/1040066d…/cookbook/recipes/markets/ingredients/templates/skeleton/app/lib/sanitizeHtml.ts returns 404.
  • https://github.com/Shopify/hydrogen/blob/<commit>/templates/skeleton/templates/skeleton/app/routes/_index.tsx returns 404.

After

commit: 68f62c423b5382cb6a98a4f0000d656bf98b9c13
  • The sanitizeHtml.ts link opens the sanitizer.
  • The Deleted Files links use /templates/skeleton/ once and open the file at the pinned commit.

What this changes

  • Sets commit in cookbook/recipes/markets/recipe.yaml to the Sanitize merchant-managed HTML in the markets recipe #4278 merge commit, and renders the markets README and LLM prompt again.
  • In cookbook/src/lib/render.ts, stops adding templates/skeleton/ to Deleted Files links. The deletedFiles paths in each recipe already start with it.
  • Fixes the same links in the express (59 links) and multipass (1 link) READMEs. The changes in those two files touch only these links. A full render of either README would also bring in other recipe changes that nobody has rendered yet, so this PR does not do one.

Developer impact

No changeset. The cookbook does not ship in a package.

Out of scope

  • The shopify.dev page is in shop/world. A separate PR updates it.
  • pnpm run cookbook regenerate sets commit automatically, but it runs apply first, and apply fails on the markets package.json patch. This PR sets commit by hand.

How to Test

  1. Open cookbook/recipes/markets/README.md on this branch.
  2. Select the app/lib/sanitizeHtml.ts link in the ingredients table.
  3. Confirm that GitHub shows the sanitizer file and not a 404.
  4. Select any link under "Deleted Files", in the markets, express or multipass README.
  5. Confirm that GitHub shows the file and not a 404.

@lucyxiang
lucyxiang requested a review from a team as a code owner November 2, 2026 17:52
@shopify

shopify Bot commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

Oxygen deployed a preview of your lucy/markets-recipe-commit branch. Details:

Storefront Status Preview link Deployment details Last update (UTC)
Skeleton (skeleton.hydrogen.shop) ✅ Successful (Logs) Preview deployment Inspect deployment November 2, 2026 7:35 PM

Learn more about Hydrogen's GitHub integration.

@fredericoo fredericoo left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Checked that every link except the Deleted Files ones (see inline) resolves at 68f62c4, and that render and generateLLMsFiles reproduce both files byte-for-byte from the new recipe.yaml.

Comment thread cookbook/recipes/markets/README.md Outdated
- [templates/skeleton/app/routes/policies.$handle.tsx](https://github.com/Shopify/hydrogen/blob/1040066d20b52667756fd1ebffd8607602a735b4/templates/skeleton/templates/skeleton/app/routes/policies.$handle.tsx)
- [templates/skeleton/app/routes/policies._index.tsx](https://github.com/Shopify/hydrogen/blob/1040066d20b52667756fd1ebffd8607602a735b4/templates/skeleton/templates/skeleton/app/routes/policies._index.tsx)
- [templates/skeleton/app/routes/search.tsx](https://github.com/Shopify/hydrogen/blob/1040066d20b52667756fd1ebffd8607602a735b4/templates/skeleton/templates/skeleton/app/routes/search.tsx)
- [templates/skeleton/app/routes/account.$.tsx](https://github.com/Shopify/hydrogen/blob/68f62c423b5382cb6a98a4f0000d656bf98b9c13/templates/skeleton/templates/skeleton/app/routes/account.$.tsx)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

non-blocking: these 20 Deleted Files links still 404, because the path has templates/skeleton/ twice.

Reproduced: none of the 20 paths exist in the 68f62c4 tree; the same paths with a single templates/skeleton/ all do.

deletedFiles entries already start with templates/skeleton/, and render.ts adds it again. This predates the PR and also affects the express and multipass READMEs, so it's out of scope here. Worth a follow-up in render.ts:

// before
`${linkPrefix}/templates/skeleton/${file}`
// after
`${linkPrefix}/${file}`

The markets recipe README and LLM prompt link to files at the commit
in recipe.yaml. That commit was older than #4278, so the links to
sanitizeHtml.ts returned 404. Set the commit to the #4278 merge commit
and render the README and prompt again.

The Deleted Files links also returned 404. The deletedFiles paths
already start with templates/skeleton/, and render.ts added that
prefix again. Remove the extra prefix, and fix the same links in the
express and multipass READMEs.
@lucyxiang
lucyxiang force-pushed the lucy/markets-recipe-commit branch from dede094 to 8dedcd0 Compare November 2, 2026 19:33
@lucyxiang lucyxiang changed the title Pin the markets recipe docs to the sanitizer merge commit Fix the markets recipe doc links and the Deleted Files links Nov 2, 2026
@lucyxiang
lucyxiang enabled auto-merge November 2, 2026 19:42
@lucyxiang
lucyxiang added this pull request to the merge queue Nov 2, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Nov 2, 2026
@lucyxiang
lucyxiang added this pull request to the merge queue Nov 2, 2026
Merged via the queue into 2026-04 with commit f0140a3 Nov 2, 2026
21 checks passed
@lucyxiang
lucyxiang deleted the lucy/markets-recipe-commit branch November 2, 2026 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants