poly-theme-cli

This module contains cli tools for theme developers.

Usage no npm install needed!

<script type="module">
  import polyThemeCli from 'https://cdn.skypack.dev/poly-theme-cli';
</script>

README

Poly Theme Cli

A set of common cli tools used for poly theme development

Installation

npm install poly-theme-cli --save-dev

Update "scripts" in package.json to access the hstheme in the repo.

"scripts": {
    "hstheme: "hstheme",
    ...
}

Setup local.config.js

npm run hstheme setup:local

User would be prompted to provide organization id and hearsay api token.

Fetch Slug

npm run hstheme fetch:slug <slug>

If the slugs exists in the organization then data for the slug will be fetched and stored in <slug>.json file and value sampleData in the local.config.js would be set to <slug>.json

Other Commands

To switch between sample data: npm run hstheme use:sample <filename>

To set the default: npm run hstheme use:default