Video
The Video
component renders a video for the Storefront API's Video object.
The component outputs a video
element. You can customize this component using passthrough props.
Example code
Anchor link to section titled "Example code"
Name | Type | Description |
---|---|---|
data | PartialDeep<VideoType> |
An object with fields that correspond to the Storefront API's Video object. |
previewImageOptions? | ShopifyLoaderParams |
An object of image size options for the video's previewImage . Uses shopifyImageLoader to generate the poster URL. |
sourceProps | HTMLAttributes |
Props that will be passed to the video element's children source elements. |
Required fields
Anchor link to section titled "Required fields"The Video
component requires the following fields from the Storefront API's
Video object:
Component type
Anchor link to section titled "Component type"The Video
component is a shared component, which means that it renders on both the server and the client. For more information about component types, refer to React Server Components.