Skip to main content

link_to_vendor

string | link_to_vendor
returns string

Generates an HTML <a> tag with an href attribute linking to a collection page that lists all products of a given product vendor.

{{ "Polina's Potent Potions" | link_to_vendor }}

Output

<a href="/collections/vendors?q=Polina%27s%20Potent%20Potions" title="Polina&#39;s Potent Potions">Polina's Potent Potions</a>
string | link_to_vendor: attribute: string

You can specify HTML attributes by including a parameter that matches the attribute name, and the desired value.

{{ "Polina's Potent Potions" | link_to_vendor: class: 'link-class' }}

Output

<a class="link-class" href="/collections/vendors?q=Polina%27s%20Potent%20Potions" title="Polina&#39;s Potent Potions">Polina's Potent Potions</a>
Was this page helpful?