This is a Shopify app template written in Golang, that bootstraps the app building process. It includes:
- The setup of the client and server parts, built on top of the App Bridge.
- Shopify app installation logic.
- Examples of using the Shopify API include creating store products and counting the number of products.
Please ensure that the following software is installed on your computer:
-
Clone the template using the following terminal command:
git clone https://github.com/antflydb/shopify-app-template-go.git my-shopify-app cd my-shopify-app shopify app init -
Install NPM dependencies:
npm i -
Choose your database option:
Option A: PostgreSQL with Docker (default)
Start a new Postgres container using the configuration in the
.local.envfile:docker-compose --env-file .local.env up --build postgresdbOption B: SQLite (no Docker required)
Simply set the database type to SQLite. No additional setup needed:
export DATABASE_TYPE=sqliteOr create a
.local.envfile and add:DATABASE_TYPE=sqlite SQLITE_PATH=./app.db -
Run the project:
With PostgreSQL:
npm run devWith SQLite:
DATABASE_TYPE=sqlite npm run dev