Recs Fallback Query
In some cases, it can be desirable to apply a "fallback" query to Smart Recommendation banners where the applied logic might equate to no results found.
For example: when first installing Smart Recommendations "Checkout/Cart" logic for "Also bought Together" banners, there may not be enough initial data to qualify a result.
Any of the API options for Smart Recommendations can be applied to the fallback query.
In the example below, a "Trending Products" (RECS_TRENDING) query replaces the target Recommendations banner if no results are found.
Note: Apply the target klevu-recs banner id to the klevu_recsFallBackId variable.
Note: Also adjust the templateData.metadata.title to match the intent of the fallback query.
See : Overview for more details on the functions used in the above example.