- Create a metafield and copy its name with type. Like a metafield (video_text_section_01_video_url_) created
for collection editor should be copied as:
collection.metafields.custom.video_text_section_01_video_url_
And created for product:
product.metafields.custom.video_text_section_01_video_url_
And soo on..
2- Go to a section in customize/editor that you want to show or hide on base if meta field is added or not. Add a “custom liquid code†section there. You can add this anywhere in same template. Then Open that page in new tab and copy id of that specific section via inspect element. In this case id was: #shopify-section-template--23750966640949__text_video_section_jJQDcz
2- Add this code in that custom liquid code section
{% if
collection.metafields.custom.video_text_section_01_video_url_ == blank %}
<style>
#shopify-section-template--23750966640949__text_video_section_jJQDcz {
display: none
}
</style>
{% endif %}
Hurrah – Done
