WeChat Store Product
WdStoreProduct
Usage Instructions
The WeChat Mini Program embeds WeChat Store products, displays store products, and redirects to transactions. It supports the Store Preferred Alliance's product promotion and commission function.
Component Usage Limitations
The component must be used in a real Mini Program environment to observe the actual effect.
Due to platform rules, keep the component content fully displayed. If you need to customize styles, use custom-style. The number and spacing of component elements, product guarantee content and sales data, component font size, and the height of the "Buy" button cannot be modified. Failure to comply will render the component unavailable and may result in suspension of the ability to use this component.
This component is currently not supported in Mini Programs on WeChat for Windows or WeChat for Mac.
Parameters product-promotion-link and media-id must be passed during the initial loading of the component. Adjusting parameters after the component has finished loading is not currently supported.
Properties
External properties received by the component
Property Name | Property Identifier | Type | Description |
|---|
| Small Shop appid | appid | string | |
| product id | productId | string | |
| promoted product commission info | productPromotionLink | string | |
| media file id | mediaId | string | |
| custom styles | customStyle | object | |
| Enable customization slot | customContent | boolean | Enable customization slot. When enabled, you can control the card content. Example: false |
| Redirect page | openPage | string | |
| logo location | logoPosition | string | Example: "bottom-left" |
Events
Events exposed by the component. You can listen to component events to trigger external actions
Event Name | Event Code | Event Output Parameters event.detail | Applicable Scenarios | Description |
|---|
| Redirect to the store successfully | bindentersuccess | Mini Program | - | |
| Failed redirection callback | bindentererror | object
| Mini Program | - |