The routes object

You can use the routes object to generate dynamic URLs to your storefront. By using them instead of hardcoded links, you can make sure your theme supports any changes to the URL format. For example, you can use the routes object to support multiple languages in your theme.

The routes object has the following attributes:

routes.root_url

Returns the base URL of the shop.

routes.account_url

Returns the URL for the account page.

routes.account_login_url

Returns the URL for the account login page.

routes.account_logout_url

Returns the URL to log the customer out of their account.

routes.account_register_url

Returns the URL for the account registration page.

routes.account_addresses_url

Returns the URL for the page where the customer can manage the addresses associated with their account.

routes.collections_url

Returns the URL for the collections page.

routes.all_products_collection_url

Returns the URL for the collection th