{"id":13902741,"url":"https://github.com/andrewsolonets/Azon-Shop","last_synced_at":"2025-07-18T00:31:59.193Z","repository":{"id":65024664,"uuid":"572678541","full_name":"andrewsolonets/Azon-Shop","owner":"andrewsolonets","description":"T3-stack E-commerce website with Drizzle ORM, rating system,  persistent cart, discounts, algolia search, optimistic updates (React Query), in stock indicator, infinite scroll and order tracking. E2E Cypress tests included","archived":false,"fork":false,"pushed_at":"2025-02-21T09:13:49.000Z","size":5959,"stargazers_count":85,"open_issues_count":0,"forks_count":11,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-05-20T04:03:19.301Z","etag":null,"topics":["algolia","clerk","drizzle-orm","ecommerce","nextjs","optimistic-updates","prisma","rating-system","ratings","react","reactquery","shadcn-ui","sql","t3-stack","tailwindcss","trpc"],"latest_commit_sha":null,"homepage":"https://azon-shop.vercel.app/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/andrewsolonets.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-11-30T19:47:15.000Z","updated_at":"2025-05-09T18:03:40.000Z","dependencies_parsed_at":"2023-11-26T02:24:09.590Z","dependency_job_id":"5fce4b20-322a-471d-a218-e5fcc01d8c57","html_url":"https://github.com/andrewsolonets/Azon-Shop","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/andrewsolonets/Azon-Shop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewsolonets%2FAzon-Shop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewsolonets%2FAzon-Shop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewsolonets%2FAzon-Shop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewsolonets%2FAzon-Shop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/andrewsolonets","download_url":"https://codeload.github.com/andrewsolonets/Azon-Shop/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andrewsolonets%2FAzon-Shop/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265685524,"owners_count":23811191,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algolia","clerk","drizzle-orm","ecommerce","nextjs","optimistic-updates","prisma","rating-system","ratings","react","reactquery","shadcn-ui","sql","t3-stack","tailwindcss","trpc"],"created_at":"2024-08-06T22:01:21.879Z","updated_at":"2025-07-18T00:31:59.176Z","avatar_url":"https://github.com/andrewsolonets.png","language":"TypeScript","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"readme":"# Azon Shop\n\nE-commerce website built with the modern t3-stack (typescript, drizzle, trpc, next.js app router)\n(see v1 for older t3-stack implementation w/ prisma)\n\n## Features\n\n- Fully functioning, persistent Cart\n- Infinite scroll\n- Rating System\n- User profile with order history\n- Checkout with Stripe\n- Custom db with orders connected to Stripe\n- Authentication w/ Clerk\n- Algolia Autocomplete search\n- Product discounts and price history\n- E2E tests w/ Cypress\n\n## Migration from pages to app router\n\nThe current version was migrated to use app router along drizzle ORM and clerk auth. v1 branch is saved as a reference, built with pages router, prisma and next auth.\n\n## Environment Variables\n\nTo run this project, you will need to add the environment variables from .env.example to your .env file\n\n## Run Locally\n\nClone the project\n\n```bash\n  git clone https://github.com/andrewsolonets/Azon-Shop.git\n```\n\nGo to the project directory\n\n```bash\n  cd Azon-Shop\n```\n\nInstall dependencies\n\n```bash\n  npm install\n```\n\nConnect to your db, update drizzle integration if not using PostgreSQL\n\n```bash\nin .env\n  POSTGRES_URL=\n```\n\nAdd all the vars to the .env\n\n## Set up Algolia\n\n1. Go to `algoliaSeed.ts` and change `\"azon1\"` to your index name:\n\n   ```typescript\n   await client.saveObjects({ indexName: \"azon1\", objects: objectsToAdd });\n   ```\n\n2. Go to `Search.tsx` and change:\n\n   - `sourceId: \"AzonShop\"` to your Algolia application name.\n   - `indexName: \"azon1\"` to your index.\n\n## Seeding the Database\n\nOnce you've completed the setup for Algolia and added the necessary environment variables, proceed with seeding your database with products.\n\n**Seed the Database:** Run the following commands in your terminal:\n\n```bash\n npm run db:productSeed\n```\n\n```bash\n npm run db:pricingSeed\n```\n\n```bash\n npm run db:ratingsSeed\n```\n\n```bash\n npm run db:algoliaSeed\n```\n\n### Checking the Changes\n\nAfter the seeding process completes:\n\n- **Algolia Dashboard:** Visit the Algolia dashboard to see your data indexed based on your seeding.\n\n- **Drizzle Studio:** Access Drizzle Studio using the following command:\n\n  ```bash\n  npm run db:studio\n  ```\n\n  Use Drizzle Studio to examine your database and verify the seeded data.\n\nStart the server\n\n```bash\n  npm run dev\n```\n\n# Tech stack\n\n## V.2 (main branch)\n\n**Client:** React, Next.js (app router), Shadcn, React Query, TailwindCSS, Clerk.\n**Server:** Next.js, trpc, Drizzle ORM, PostgreSQL (Vercel DB).\n\n## V.1 - older t3 stack\n\n**Client:** React, React Query, TailwindCSS, nextauth.js.\n**Server:** Next.js, trpc, prisma, planetscale.\n(see v1 branch)\n\n## Learn More\n\nTo learn more about the [T3 Stack](https://create.t3.gg/), take a look at the following resources:\n\n- [Documentation](https://create.t3.gg/)\n- [Learn the T3 Stack](https://create.t3.gg/en/faq#what-learning-resources-are-currently-available) — Check out these awesome tutorials\n\nYou can check out the [create-t3-app GitHub repository](https://github.com/t3-oss/create-t3-app) — your feedback and contributions are welcome!\n\n## How do I deploy this?\n\nFollow our deployment guides for [Vercel](https://create.t3.gg/en/deployment/vercel) and [Docker](https://create.t3.gg/en/deployment/docker) for more information.\n\n## TODO\n\n- [ ] Implement e2e testing with Cypress\n  - [x] Write tests for the navigation bar\n  - [x] Test adding a product to the cart.\n  - [x] Test mobile menu\n  - [x] Single product page\n    - [x] Test Quantity buttons\n- [ ] Quick buy feature w/ next.js modal setup\n- [ ] Add metadata to each route\n- [x] Move from Prizma to Drizzle ORM\n- [x] Migrate from pages to app router (next js)\n- [x] Use shadcn where reasonable\n- [x] Integrate Sentry for error tracking\n- [x] Algolia search\n- [x] Discounts feature: discount component\n- [x] Discounts feature: use discounted price on checkout and cart\n- [x] Product description use accordion shadcn\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandrewsolonets%2FAzon-Shop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandrewsolonets%2FAzon-Shop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandrewsolonets%2FAzon-Shop/lists"}