Code Monkey home page Code Monkey logo

hydrogen-theme's Introduction

Hydrogen Theme

Build status License: MIT

A port of Hydrogen's default template to Shopify OS 2.0.

pika-1697163139924-1x

๐Ÿ”จ Requirements

๐Ÿš€ Project Structure

This theme leverages the default Shopify theme folder structure and introduces the following directories, some of which have special behaviors.

โ””โ”€โ”€ hydrogen-theme
    โ””โ”€โ”€ frontend
        โ”œโ”€โ”€ entrypoints
        โ”œโ”€โ”€ islands
        โ”œโ”€โ”€ lib
        โ””โ”€โ”€ styles
Subdirectory Description
entrypoints The entry points for your theme
islands The interactive islands in your theme
lib Theme specific libraries
styles The styles of your theme

๐Ÿงž Commands

Command Action
pnpm install Installs dependencies
pnpm dev --live-reload full-page Launch the Shopify and Vite servers in parallel
pnpm run deploy Bundle your theme's assets and upload your local theme files to Shopify

๐Ÿ๏ธ Hydration Directives

The following hydration strategies are available (borrowed from Astro).

Directive Description
client:idle Hydrate the component as soon as the main thread is free
client:visible Hydrates the component as soon as the element enters the viewport
client:media Hydrates the component as soon as the browser matches the given media query

Usage:

<my-component client:visible>This is an island.</my-component>

๐Ÿ™‡โ€โ™‚๏ธ Thanks

We would like to specifically thank the following projects for the inspiration and help regarding the creation of hydrogen-theme:

hydrogen-theme's People

Contributors

montalvomiguelo avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.