diff --git a/packages/js/product-editor/changelog/dev-44239_change_number_of_choose_products_for_me b/packages/js/product-editor/changelog/dev-44239_change_number_of_choose_products_for_me new file mode 100644 index 00000000000..632e997f0d9 --- /dev/null +++ b/packages/js/product-editor/changelog/dev-44239_change_number_of_choose_products_for_me @@ -0,0 +1,4 @@ +Significance: minor +Type: dev + +[Linked products] - Change number of 'choose products for me' to 4 #46094 diff --git a/packages/js/product-editor/src/utils/get-related-products/index.ts b/packages/js/product-editor/src/utils/get-related-products/index.ts index fab36cb6af8..496591c30ea 100644 --- a/packages/js/product-editor/src/utils/get-related-products/index.ts +++ b/packages/js/product-editor/src/utils/get-related-products/index.ts @@ -12,6 +12,7 @@ type getRelatedProductsOptions = { const POSTS_NUMBER_TO_RANDOMIZE = 30; const POSTS_NUMBER_TO_PICK = 3; +const POSTS_NUMBER_TO_DISPLAY = 4; /** * Return related products for a given product ID. @@ -99,6 +100,7 @@ export async function getSuggestedProductsFor( { : [], tags: data?.tags ? data.tags.map( ( tag ) => tag.id ) : [], exclude: exclude?.length ? exclude : [ postId ], + limit: POSTS_NUMBER_TO_DISPLAY, }; if ( forceRequest ) {