{"id":15505808,"url":"https://github.com/imranhsayed/nextjs-woocommerce-restapi","last_synced_at":"2025-04-06T03:08:31.053Z","repository":{"id":42483621,"uuid":"398778929","full_name":"imranhsayed/nextjs-woocommerce-restapi","owner":"imranhsayed","description":"A React WooCommerce Project Example With REST API","archived":false,"fork":false,"pushed_at":"2024-01-29T05:57:43.000Z","size":963,"stargazers_count":331,"open_issues_count":12,"forks_count":102,"subscribers_count":10,"default_branch":"main","last_synced_at":"2024-12-28T09:04:12.755Z","etag":null,"topics":["cart","checkout-page","decoupled","headless","headless-wordpress-framework","nextjs","nextjs-woocommerce-restapi-example","reactjs","restapi","stripe","woocommerce","wordpress"],"latest_commit_sha":null,"homepage":"nextjs-woocommerce-restapi-virid.vercel.app","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/imranhsayed.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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}},"created_at":"2021-08-22T11:07:26.000Z","updated_at":"2024-12-13T15:53:15.000Z","dependencies_parsed_at":"2024-10-31T07:04:01.326Z","dependency_job_id":"971cbd95-d3c3-4c5d-8042-07afca53dde3","html_url":"https://github.com/imranhsayed/nextjs-woocommerce-restapi","commit_stats":{"total_commits":97,"total_committers":2,"mean_commits":48.5,"dds":"0.030927835051546393","last_synced_commit":"b0746f12da01588d786f6dc163275fb0047d8e16"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranhsayed%2Fnextjs-woocommerce-restapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranhsayed%2Fnextjs-woocommerce-restapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranhsayed%2Fnextjs-woocommerce-restapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imranhsayed%2Fnextjs-woocommerce-restapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/imranhsayed","download_url":"https://codeload.github.com/imranhsayed/nextjs-woocommerce-restapi/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247427006,"owners_count":20937201,"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":["cart","checkout-page","decoupled","headless","headless-wordpress-framework","nextjs","nextjs-woocommerce-restapi-example","reactjs","restapi","stripe","woocommerce","wordpress"],"created_at":"2024-10-02T09:24:34.520Z","updated_at":"2025-04-06T03:08:31.029Z","avatar_url":"https://github.com/imranhsayed.png","language":"JavaScript","readme":"## 🎨 Next.js WooCommerce REST API\n[![Project Status: Active.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active)\n![Stars](https://img.shields.io/github/stars/imranhsayed/nextjs-woocommerce-restapi?label=%E2%AD%90%20Stars)\n![Forks](https://img.shields.io/github/forks/imranhsayed/nextjs-woocommerce-restapi?color=%23ff69b4)\n![Contributors](https://img.shields.io/github/contributors/imranhsayed/nextjs-woocommerce-restapi?color=blue)\n![Follow](https://img.shields.io/github/followers/imranhsayed?label=Please%20follow%20%20to%20support%20my%20work%20%F0%9F%99%8F\u0026style=social)\n\n- React WooCommerce Theme, using Decoupled Architecture in Next.js\n- Backend in WordPress\n- Front end in React.\n- Data is Fetched through REST API.\n\n## Features\n- [x] Home Page\n- [x] Single Product Page With Gallery Carousel.\n- [x] Cart Page\n- [x] Checkout Page with Stripe Payment Gateway Integration.\n- [x] REST API endpoints.\n- [x] Header and Footer in Next.js fetching from WordPress Menu items.\n- [x] WordPress Widgets displayed on Next.js frontend.\n- [x] Site title, tagline, copyright text, social links sourced from WordPress.\n- [x] Yoast SEO support\n- [x] Next.js Image component, that has image optimization at request time\n- [x] Incremental Static (Re)generation and automatic creation of New Static product pages\nwithout having to re-build next.js the application.\n- [x] Gutenberg styles support\n- [x] Blog Page with Pagination\n- [x] Single Post\n- [x] Pages\n- [x] 404 Page\n- [x] Display Comments\n- [x] Post a Comment ( using a Comment Form )\n- [ ] Post Preview ( Coming Soon )\n- [ ] Product Pagination ( Coming Soon )\n- [ ] Load More Products ( Coming Soon )\n- [ ] Authentication with JWT and Http Only Cookie implementation. ( Coming Soon )\n- [ ] Login feature for WP Post Preview in Next.js ( Coming Soon )\n\n## [Tutorial Course](https://www.youtube.com/playlist?list=PLD8nQCAhR3tSRwsvzRtogv9MFkEWo5d9c)\n\n## [Live Demo Link](https://nextjs-woocommerce-restapi-virid.vercel.app/)\n\n## Setup\n\nFirst clone/fork the repo and cd into it.\n\n```bash\ngit clone https://github.com/imranhsayed/nextjs-woocommerce-restapi.git\ncd nextjs-woocommerce-restapi\nnpm ci\nnpm run dev\n```\n\n## Add Headless features for WordPress\n\n- Install and Activate following WordPress Plugins:\n\n* [headless-cms](https://github.com/imranhsayed/headless-cms)\n* [woocommerce](https://wordpress.org/plugins/woocommerce/)\n\n## Configuration :wrench:\n\n1. (Required) Create a `.env` file taking reference from `.env-example` and update your WordPressSite URL and Frontend next.js URL.\n- `NEXT_PUBLIC_WORDPRESS_URL=https://example.com`\n- `NEXT_PUBLIC_SITE_URL=http://localhost.com` ( This will be your frontend Next.js URL)\n\n2. Add your `WC_CONSUMER_KEY` and `WC_CONSUMER_SECRET` to the `.env` by following [WooCommerce \u003e Settings \u003e Advanced \u003e REST API](https://woocommerce.github.io/woocommerce-rest-api-docs/#authentication)\n\n2. In your WordPress Dashboard, Go to Settings \u003e General \u003e Site Address (URL) ( Set this to Frontend URL e.g. http://localhost:3000 during development )\n3. Create the Header and Footer Menus In WordPress Dashboard and set them to HCMS Header menu and HCMS Footer Menu respectively.\n\n## Useful Links\n- [Stripe](https://dashboard.stripe.com/)\n- [Getting Stripe API Keys](https://codeytek.com/create-stripe-checkout-in-next-js-stripe-session-stripe-webhook/)\n\n## Versioning :bookmark_tabs:\n\nI use [Git](https://github.com/) for versioning.\n\n## Author :bust_in_silhouette:\n\n* **[Imran Sayed](https://twitter.com/imranhsayed)**\n\n## License :page_with_curl:\n\nThis project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimranhsayed%2Fnextjs-woocommerce-restapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimranhsayed%2Fnextjs-woocommerce-restapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimranhsayed%2Fnextjs-woocommerce-restapi/lists"}