Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
132 changes: 70 additions & 62 deletions packages/hydrogen-react/docs/generated/generated_docs_data.json

Large diffs are not rendered by default.

3,163 changes: 2,383 additions & 780 deletions packages/hydrogen-react/docs/generated/generated_docs_data_v2.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"type": "Generic",
"anchorLink": "authentication",
"title": "Authentication",
"sectionContent": "To use Hydrogen React, you need to authenticate with and make requests to the [Storefront API](/docs/api/storefront). Hydrogen React includes an [API client](/docs/api/hydrogen-react/2026-01/utilities/createstorefrontclient) to securely handle API queries and mutations.\n\nYou can create and manage Storefront API access tokens by installing the [Headless sales channel](https://apps.shopify.com/headless) on your store.\n\nApps have access to [two kinds of tokens](/docs/api/usage/authentication#access-tokens-for-the-storefront-api): a public API token, which can be used in client-side code, and a private API token, which should only be used in server-side contexts and never exposed publicly.",
"sectionContent": "To use Hydrogen React, you need to authenticate with and make requests to the [Storefront API](/docs/api/storefront). Hydrogen React includes an [API client](/docs/api/hydrogen-react/2026-04/utilities/createstorefrontclient) to securely handle API queries and mutations.\n\nYou can create and manage Storefront API access tokens by installing the [Headless sales channel](https://apps.shopify.com/headless) on your store.\n\nApps have access to [two kinds of tokens](/docs/api/usage/authentication#access-tokens-for-the-storefront-api): a public API token, which can be used in client-side code, and a private API token, which should only be used in server-side contexts and never exposed publicly.",
"sectionCard": [
{
"subtitle": "Install",
Expand Down
2 changes: 1 addition & 1 deletion packages/hydrogen-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
"@graphql-codegen/introspection": "^4.0.3",
"@graphql-codegen/typescript": "^4.1.3",
"@ladle/react": "^5.0.1",
"@shopify/generate-docs": "1.1.0",
"@shopify/generate-docs": "1.1.1",
"@testing-library/jest-dom": "^6.6.3",
"@testing-library/react": "^14.0.0",
"@testing-library/user-event": "^14.6.1",
Expand Down
84 changes: 45 additions & 39 deletions packages/hydrogen/docs/generated/generated_docs_data.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions packages/hydrogen/docs/generated/generated_docs_data_v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -4365,7 +4365,7 @@
"src/pagination/Pagination.ts": {
"filePath": "src/pagination/Pagination.ts",
"name": "GetPaginationVariablesGeneratedType",
"description": "",
"description": "The `getPaginationVariables` function is used with the `<Pagination>` component to generate the variables needed to fetch paginated data from the Storefront API.",
"isPublicDocs": true,
"params": [
{
Expand Down Expand Up @@ -10199,7 +10199,7 @@
"src/cart/optimistic/useOptimisticCart.tsx": {
"filePath": "src/cart/optimistic/useOptimisticCart.tsx",
"name": "UseOptimisticCartGeneratedType",
"description": "",
"description": "The `useOptimisticCart` hook takes an existing cart object, processes all pending cart actions, and locally mutates the cart with optimistic state. An optimistic cart makes cart actions immediately render in the browser while actions sync to the server.",
"isPublicDocs": true,
"params": [
{
Expand Down
2 changes: 1 addition & 1 deletion packages/hydrogen/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
"devDependencies": {
"react-router": "7.12.0",
"@react-router/dev": "7.12.0",
"@shopify/generate-docs": "1.1.0",
"@shopify/generate-docs": "1.1.1",
"@shopify/hydrogen-codegen": "workspace:*",
"@testing-library/jest-dom": "^6.6.3",
"@types/node": "catalog:",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export type OptimisticCart<T = CartReturn> = T extends undefined | null
};

/**
* The `useOptimisticCart` hook takes an existing cart object, processes all pending cart actions, and locally mutates the cart with optimistic state. An optimistic cart makes cart actions immediately render in the browser while actions sync to the server.
* @param cart The cart object from `context.cart.get()` returned by a server loader.
*
* @returns A new cart object augmented with optimistic state for `lines` and `totalQuantity`. Each cart line item that is optimistically added includes an `isOptimistic` property. Also if the cart has _any_ optimistic state, a root property `isOptimistic` will be set to `true`.
Expand Down
1 change: 1 addition & 0 deletions packages/hydrogen/src/pagination/Pagination.ts
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,7 @@ export function usePagination<NodesType>(
}

/**
* The `getPaginationVariables` function is used with the `<Pagination>` component to generate the variables needed to fetch paginated data from the Storefront API.
* @param request The request object passed to your Remix loader function.
* @param options Options for how to configure the pagination variables. Includes the ability to change how many nodes are within each page as well as a namespace to avoid URL param conflicts when using multiple `Pagination` components on a single page.
*
Expand Down
14 changes: 7 additions & 7 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading