Do well by doing good for fulfillment workers
HeyThanks is the Shopify app the enables in-store tipping for fulfillment workers. Built with Node (server), React (admin) and Vue (cart and order widgets). Served up by Heroku with a Postgres database.
Get started contributing to HeyThanks.
Make sure your development environment has the necessary prerequisites.
Node.js (v16.x) β we use nvm to manage Node.js versions.
Shopify CLI to manage Shopify apps.
VSCode β you could also use another editor, but this helps us guarantee linter/formatter features.
Volar VSCode Extension β Vue 3 language support (turn off vetur and ts/js language features if you have problems arising from conflicts).
Eslint VSCode Extension β linter and formatter.
Clone the repository, checkout a new branch from the master copy, and install all dependencies.
git clone https://github.com/localgoods/heythanks.git
cd heythanks
git pull
git checkout -b feature/tip-more master
npm install
This will install all workspace dependencies for this monorepo.
Create a .env
in the root directory and add your local Shopify app configuration.
SHOPIFY_API_KEY="your-api-key"
SHOPIFY_API_SECRET="your-api-secret"
SHOP="your-shop-url"
SCOPES=write_script_tags,write_products,read_themes,read_fulfillments,read_orders,read_products,read_customers
HOST="your-ngrok-url"
DATABASE_URL="your-postgres-url"
Run the development server for the cart widget.
npm run serve:cart-widget
Run the development server for the default application (the admin app) and backend services.
npm run serve
There are two main operations for setting up and maintaining our PG DBs. Both are shown below with the example values representing our local environment (but the same operations are used for production). For testing changes and sandboxing queries, pgAdmin is a good app to download and configure to access HT DBs.
Dump migrations from an existing DB (to download the HT schema).
pg_dump -h localhost -p 5432 -U ianherrington -d postgres -f ./heythanks_pg.sql
# Then enter password...
Migrate a DB (to upload or update the HT schema).
psql -h localhost -p 5432 -U ianherrington -d postgres -f ./heythanks_pg.sql
# Then enter password...
Todo add usage documentation for the topics below.
Special, free access to full service: