OVERVIEW
This document will outline basic information on using custom templates. For up to date information on our custom templates, please visit out developer hub. Custom templates are updated from time to time, so please check back to see when the latest update to the template was released.
This template has been made available for developers to use in order to add custom design and/or functionality to Rebuy Smart Search. If you do not have a developer, but would still like custom work done, you can speak with our partner team who can help connect you with the right partner for your request.
Our support services cover all aspects directly linked to Rebuy, providing assistance and guidance for standard features and functionalities. Please note that we do not offer support for third-party plugins or customizations like custom templates as outlined in this document. For a comprehensive list of supported items, please refer to our policy page. Please be mindful of this when proceeding.
Rebuy Smart Search is comprised of two main components. Quick View and the Results page. Each component has it's own custom template that can be employed.
Using a Quick View Template
Create a new snippet file
Inside your Shopify Admin go to the Online Store Tab then Edit Code for whichever theme you are wanting to use the custom template in.
Once inside scroll down to the snippets section in the left hand menu and click "Add a new snippet" name the snippet "rebuy-quick-view-template".
Pay close attention to the spelling here!
Add the template to the newly created snippet file
Within the snippet file you just created, you'll need to copy and paste the template code. There are 2 different layout options that can be selected for Quick View, therefore there are 2 template options to choose from.
Select the Quick View template that matches the layout option from your Quick View settings in Rebuy Admin.
Render the snippet file
Now that the snippet is created and has the template code, the finally step is to render the file so that the code is live.
Paste the following code at the bottom of your theme.liquid file above the closing body tag </body>
. You can keyword search for </body>
if needed.
{% render 'rebuy-quick-view-template' %}
Your Rebuy Search Quick View will now run off of the custom template. If you'd like to revert to default functionality at any time, simply stop rendering the template file in theme.liquid.
Using a Results Page Template
Create a new snippet file
Inside your Shopify Admin go to the Online Store Tab then Edit Code for whichever theme you are wanting to use the custom template in.
Once inside scroll down to the snippets section in the left hand menu and click "Add a new snippet" name the snippet "rebuy-results-page-template".
Pay close attention to the spelling here!
Add the template to the newly created snippet file
Within the snippet file you just created, you'll need to copy and paste the template code. There are 3 different layout options that can be selected for the Results Page, therefore there are 3 template options to choose from.
Select the Results Page template that matches the layout option from your Results Page settings in Rebuy Admin.
Render the snippet file
Now that the snippet is created and has the template code, the finally step is to render the file so that the code is live.
Paste the following code at the bottom of your theme.liquid file above the closing body tag </body>
. You can keyword search for </body>
if needed.
{% render 'rebuy-results-page-template' %}
Your Rebuy Search Results Page will now run off of the custom template. If you'd like to revert to default functionality at any time, simply stop rendering the template file in theme.liquid.
Disclaimer
As mentioned in the Overview, support for custom template work falls outside the scope of the Rebuy Support Team. Using custom templates is at your own discretion.
If you encounter an issue and are unsure whether the problem is with Rebuy Search or with the template you're using, revert to default Search by removing the template file rendering in your theme.liquid.
If the issue persists, please contact the Support Team. If the issue stops, then the source is the template. Please debug your code or pull a fresh copy of the template from the links above and begin anew.