Product validation Strategy
The viewer can render fallback content when a product does not exist in Cylindo’s Content API.
This is controlled using the product-fallback slot together with the product-validation-strategy attribute. For API documentation, see this section
When a fallback slot is defined, the viewer performs an early validation request to determine whether the product exists in CAPI and renders either the viewer or the fallback content based on the selected strategy.
The network request is intentionally delayed to better demonstrate the behavior of the different attributes.
Strategy:
Product (change to re-run):
Fallback
This product is not available in Cylindo.
<cylindo-viewer
customer-id="5098"
code="fake product"
product-validation-strategy="blocking"
style="max-height: 600px; max-width: 1200px;"
>
<div slot="product-fallback" style="padding: 16px;">
<strong>Fallback</strong>
<div>This product is not available in Cylindo.</div>
</div>
</cylindo-viewer>
info
Product validation only checks whether the product exists in CAPI.
It does not validate product configuration, options, or features.