Skip to content

Instantly share code, notes, and snippets.

@juque
Created November 14, 2013 19:38
Show Gist options
  • Select an option

  • Save juque/7472982 to your computer and use it in GitHub Desktop.

Select an option

Save juque/7472982 to your computer and use it in GitHub Desktop.
<!-- breadcrumbs -->
<h2><!-- [colección] / [tipo] / [etiqueta] -->
{% if collection and product_type and tag %}
<a href="{{shop.url}}">Home</a> >
<a href="{{collection | typed_collection_path:product_type}}">
{{collection.title}} > {{product_type.name}}</a> > {{tag}}
<!-- [colección] / [tipo] -->
{% elsif collection and product_type %}
<a href="{{shop.url}}">Home</a>
<a href="{{collection.url}}">{{collection.title}}</a> > {{product_type.name}}
<!-- [colección] / [etiqueta] -->
{% elsif collection and tag %}
<a href="{{shop.url}}">Home</a> >
<a href="{{collection.url}}">{{collection.title}}</a> > {{tag.name}}
<!-- [tipo] / [etiqueta] -->
{% elsif product_type and tag %}
<a href="{{shop.url}}">Home</a> >
<a href="{{product_type.url}}">{{product_type.name}}</a> > {{tag.name}}
<!-- [tipo] -->
{% elsif product_type %}
{{ product_type.name }}
<!-- [colección, nombre de producto u otros] -->
{% elsif resource %}
<a href="{{shop.url}}">Home</a> > {{collection.title}}
<!-- Todos los productos -->
{% else %}
<a href="{{shop.url}}">Home</a> > {{resource.name}} > {{ product.model }}
{% endif %}
</h2>
<!-- /breadcrumbs -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment