Shopify themes, liquid, logos, and UX
I would like to give website managers the ability to easily edit a custom html/liquid banner element using the customizer. Specifically, using a link list dropdown.
{
"type": "link_list",
"id": "button_link",
"label": "Button Link"
}
Here is the liquid in settings-schema, but what do I need to put in my template file to actually get this information to do something?
The code below will output the handle of the link list.
{{ settings.button_link }}
The code below will output the link list as an object.
linklists[settings.button_link]
Below is an example of outputting the links within the list.
{% for link in linklists[settings.button_link].links %}
<a href="{{ link.url }}">{{ link.title }}</a>
{% endfor %}
You're a genius. Thank you so much.
Bacon saved!
this is the stuff that should be in the shopify docs
User | RANK |
---|---|
127 | |
95 | |
77 | |
69 | |
39 |
Learn these 5 things I had to learn the hard way with starting and running my own business
By Kitana Jan 27, 2023Would you love to unleash the unbridled power of the Google Shopping Channel into your sho...
By Gabe Jan 6, 2023How can you turn a hobby into a career? That’s what Emmanuel did while working as a wa...
By Skye Dec 30, 2022