Shopify Theme 2.0 Directory Structure
Shopify Theme 2.0 follows a well-organized directory structure, allowing developers to create flexible and customizable themes. Below is a detailed breakdown of each folder and its purpose
Short Structure
├── assets
├── config
├── layout
├── locales
├── sections
├── snippets
└── templates
└── customers
Descriptive Structure
/shopify-engine-theme/ # Root directory of the Shopify theme
│── /assets/ # Contains static assets like CSS, JS, images, fonts
│ ├── theme.css # Main CSS file for styling
│ ├── theme.js # Main JavaScript file for interactive features
│ ├── logo.png # Example of an image file
│
│── /layout/ # Contains global layout files
│ ├── theme.liquid # Main layout file, includes global elements (header, footer)
│
│── /locales/ # Stores translations for multi-language support
│ ├── en.default.json # English translation file
│ ├── bn.default.json # Bangla translation file (example)
│
│── /sections/ # Reusable components that can be added to different pages
│ ├── header.liquid # Header section
│ ├── footer.liquid # Footer section
│ ├── featured-collection.liquid # A section to display featured products
│ ├── product-gallery.liquid # A section to show product images
│
│── /snippets/ # Small reusable code pieces included in sections/templates
│ ├── price.liquid # Displays formatted product prices
│ ├── breadcrumbs.liquid # Navigation breadcrumbs
│ ├── rating-stars.liquid # Star rating component for products
│
│── /templates/ # Defines page structure using JSON (or Liquid for some cases)
│ ├── index.json # Homepage structure (configurable with sections)
│ ├── product.json # Product page structure
│ ├── collection.json # Collection page structure
│ ├── 404.json # 404 error page
│ ├── cart.json # Shopping cart page
│ │── /customers/ # Templates for customer account pages
│
└── /config/ # Theme configurations and metadata
├── settings_schema.json # Defines settings available in the Shopify theme editor
├── settings_data.json # Theme settings saved by the merchant