Sitemap
Rajeev Kumar

Rajeev Kumar

Founder & CEO @ RND Experts Pvt Ltd, LinkedIn - https://www.linkedin.com/in/rajeevsharma2/

๐‡๐จ๐ฐ ๐ญ๐จ ๐‚๐ซ๐ž๐š๐ญ๐ž ๐‚๐ฎ๐ฌ๐ญ๐จ๐ฆ ๐’๐ž๐œ๐ญ๐ข๐จ๐ง๐ฌ ๐ข๐ง ๐’๐ก๐จ๐ฉ๐ข๐Ÿ๐ฒ?

1 min readMay 6, 2024

Creating custom sections in Shopify allows you to add unique content and functionality to your store beyond the standard theme options. Hereโ€™s a breakdown of the process:

๐Ÿ. ๐€๐œ๐œ๐ž๐ฌ๐ฌ ๐“๐ก๐ž๐ฆ๐ž ๐‚๐จ๐๐ž:

a. Go to your Shopify admin panel.

b. Navigate to โ€œOnline Storeโ€ > โ€œThemesโ€.

c. Select the theme you want to edit and click โ€œActionsโ€ > โ€œEdit codeโ€.

๐Ÿ. ๐‚๐ซ๐ž๐š๐ญ๐ž ๐ญ๐ก๐ž ๐’๐ž๐œ๐ญ๐ข๐จ๐ง ๐…๐ข๐ฅ๐ž:

a. Inside the โ€œsectionsโ€ folder, create a new Liquid file with your desired section name (e.g., โ€œcustom-section.liquidโ€).

๐Ÿ‘. ๐ƒ๐ž๐Ÿ๐ข๐ง๐ž ๐ญ๐ก๐ž ๐’๐ž๐œ๐ญ๐ข๐จ๐ง ๐’๐œ๐ก๐ž๐ฆ๐š:

a. Within the Liquid file, start by defining the section schema using JSON. This specifies the sectionโ€™s name, settings, and presets.

b. Essential properties include:

i. name: A unique identifier for your section.

Get Rajeev Kumarโ€™s stories inย yourย inbox

Join Medium for free to get updates fromย thisย writer.

ii. settings: An array defining any customizable options within the section (e.g., text fields, image upload).

iii. presets: An array defining different variations of the section (optional).

๐Ÿ’. ๐ƒ๐ž๐ฏ๐ž๐ฅ๐จ๐ฉ ๐ญ๐ก๐ž ๐’๐ž๐œ๐ญ๐ข๐จ๐ง ๐‚๐จ๐ง๐ญ๐ž๐ง๐ญ:

a. After the schema, write the Liquid code to build the actual section content. This involves using Liquid tags and logic to display the desired elements.

๐Ÿ“. ๐“๐ž๐ฌ๐ญ ๐š๐ง๐ ๐€๐๐ ๐ญ๐ก๐ž ๐’๐ž๐œ๐ญ๐ข๐จ๐ง:

a. Go to โ€œCustomize themeโ€ in the theme editor.

b. Under โ€œSectionsโ€, click โ€œAdd sectionโ€.

c. Search for your newly created section and add it to the desired page template.

d. Save your changes and preview the storefront to ensure everything works as intended.

For more info..here is ๐’๐ก๐จ๐ฉ๐ข๐Ÿ๐ฒ ๐ƒ๐จ๐œ๐ฎ๐ฆ๐ž๐ง๐ญ๐š๐ญ๐ข๐จ๐ง: ๐Ÿ˜Š

https://shopify.dev/docs/themes/architecture/sections

#rndexperts Shopify #development #customsections #Shopify_sections #liquidfile #eCommerce #hiredeveloper

--

--