link
Menu navigation links.
Properties
Returns true if the link is active. Returns false if not.A link is considered to be active if the current URL path matches, or contains, the link's url. For example, if the current URL path is /blog/potion-notions/new-potions-for-spring, then the following link URLs would be considered active:
- /blog/potion-notions/new-potions-for-spring
- /blog/potion-notions
The link.active property is useful for designing the appearance of the currently selected menu navigation. For instance, if a customer is viewing an article in the "Tag" blog, the "Tag" link would be highlighted in the menu.
Returns true if a link's child link is active. Returns false if not.A link is considered to be active if the current URL path matches, or contains, the URL of the link.For example, if the current URL path is /blog/potion-notions/new-potions-for-spring, then the following link URLs would be considered active:
- /blog/potion-notions/new-potions-for-spring
- /blog/potion-notions
Returns true if the current URL path aligns with any of the link's child URLs. Otherwise, it returns false.
Ignore parameters when matching URLs. Product URLs within a collection context using the within helper are treated the same as standard product URLs.
Returns true if the current URL path corresponds to the link's URL. Otherwise, it returns false.
Ignore parameters when matching URLs. Product URLs within a collection context using the within helper are treated the same as standard product URLs.
The handle of the link.
The quantity of nested levels beneath the link.
The child links of the link.
The title of the link.
The type of the link.
Valid property values include:
- article_link link directs to an article.
- blog_link link directs to a blog collection.
- catalog_link link directs to all product collections.
- collection_link link directs to a product collection.
- collections_link link directs to a collection list page. Collection list page.
- frontpage_link link directs to the homepage.
- http_link link directs to an external webpage.
- page_link link directs to a custom page.
- policy_link link directs to a policy page.
- product_link link directs to a product page.
- search_link link directs to a search page.
The URL of the link.