theme-shopify-html-data-comments

Provides HTML/CSS/JS linting and formatting standards for the web industry.

2|1|Updated Feb 9, 2026
One-click install
npx skills add https://github.com/Niccos-Shopify-Workspace/shopify-cursor-skills --skill theme-shopify-html-data-comments
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: theme-shopify-html-data-comments
Source: https://github.com/Niccos-Shopify-Workspace/shopify-cursor-skills/tree/main/skills/theme-shopify-html-data-comments
Command: npx skills add https://github.com/Niccos-Shopify-Workspace/shopify-cursor-skills --skill theme-shopify-html-data-comments

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides clear guidelines for structuring HTML, using data attributes effectively, and writing concise, meaningful comments within Shopify theme development, leading to more maintainable and understandable code.

Core Features & Use Cases

  • Semantic HTML Structure: Encourages the use of semantic tags for better accessibility and SEO.
  • Data Attribute Usage: Demonstrates how to pass data from Liquid to JavaScript using data-* attributes.
  • Comment Best Practices: Outlines when and how to use comments effectively in Liquid, HTML, and snippets, focusing on explaining the "why" rather than the "what".
  • Use Case: When developing a new product card component, use this Skill to ensure the HTML is semantic, data attributes are correctly implemented for interactivity, and comments clearly explain any complex logic or usage instructions.

Quick Start

Apply the theme-shopify-html-data-comments skill to structure the HTML and add appropriate comments for a new product card section.

Frequently Asked Questions about theme-shopify-html-data-comments

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I use data attributes to pass Shopify Liquid variables to JavaScript?

To pass Shopify Liquid variables to JavaScript, use standard HTML data attributes with kebab-case naming conventions. This approach cleanly separates server-side data from client-side logic, ensuring maintainability and clear data transfer boundaries.

What are the best practices for writing comments in Shopify theme development?

The best practice for Shopify theme comments is to explain the 'why' rather than the 'what' across Liquid, HTML, and snippets. Concise, meaningful comments clarify complex logic and usage instructions, leading to more maintainable and understandable theme code.

How do I structure semantic HTML for a new Shopify product card component?

Structuring semantic HTML for a Shopify product card involves using appropriate semantic tags to improve accessibility and SEO. This ensures the component is correctly interpreted by browsers and assistive technologies while maintaining a clean HTML structure.

Do I need to follow specific naming conventions for data attributes in Shopify themes?

Yes, you should use kebab-case naming conventions for data attributes in Shopify themes. Consistent naming ensures clarity when passing data from Liquid to JavaScript and helps maintain a structured, readable, and accessible codebase.

When should I use Liquid comments versus HTML comments in Shopify theme development?

Use Liquid comments for server-side logic explanations and HTML comments for structural notes, ensuring neither renders visible output to the end-user. Both should focus on explaining the 'why' behind complex code blocks to aid future maintainability.

Does using semantic HTML in Shopify themes improve accessibility and SEO?

Yes, using semantic HTML in Shopify themes directly improves both accessibility and SEO. Proper semantic tags allow search engines to better understand content structure and assistive technologies to navigate pages accurately, creating a more robust user experience.