Earlier this year Shopify announced they would be deprecating SASS. They suggested developers use css or compile scss files using gulp or webpack. One of the issues created by that was instead of running theme watch
in one terminal, I now needed a second terminal running webpack --watch
to compile sass. It was a mess.
So I created a tiny starter project to get up and running quickly using a single command. Everything for a store gets compiled in a ./dist
folder that can be deployed to Shopify.
# Create config
> npm run create:config -- \
--env=development \
--store=mystore.myshopify.com \
--password=xxxx \
--theme_id=xxxxx
# watch files for local dev. Builds and deploys to non-live theme.
> npm run watch
# deploy site using NODE_ENV and config.yml settings
> npm run deploy
There’s even a sample github action for automatic deployments!
View on Github