Last active
August 30, 2021 08:46
-
-
Save liamgriffin/8609ee49e4a0efd8e775448a99d3da3e to your computer and use it in GitHub Desktop.
How to Create Your First Shopify Theme Section | Custom Text Section with Presets
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="custom-text-section"> | |
<h2> {{ section.settings.custom_text_title }} </h2> | |
<div>{{ section.settings.custom_text_body }}</div> | |
</div> | |
{% schema %} | |
{ | |
"name": "Text Box", | |
"settings": [ | |
{ | |
"id": "custom_text_title", | |
"type": "text", | |
"label": "Text box heading", | |
"default": "Title" | |
}, | |
{ | |
"id": "custom_text_body", | |
"type": "richtext", | |
"label": "Add custom text below", | |
"default": "<p>Add your text here</p>" | |
} | |
], | |
"presets": [ | |
{ | |
"name": "custom-text", | |
"category": "Custom" | |
} | |
] | |
} | |
{% endschema %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment