{"id":13632383,"url":"https://github.com/movahedan/next-boilerplate","last_synced_at":"2026-02-03T08:30:56.965Z","repository":{"id":46065737,"uuid":"403158073","full_name":"movahedan/next-boilerplate","owner":"movahedan","description":"A well-structured production-ready Next.js boilerplate with a well-documented directory structuring that supports Typescript, Jest, react-testing-library, Cypress, configurable Fetch and SWR, and a configured component library using Emotion, twin.macro, Tailwind, and Storybook. Plus, taking advantage of NextSeo and NextSitemap.","archived":false,"fork":false,"pushed_at":"2021-12-17T13:15:32.000Z","size":4048,"stargazers_count":21,"open_issues_count":1,"forks_count":6,"subscribers_count":5,"default_branch":"main","last_synced_at":"2024-11-09T00:34:43.510Z","etag":null,"topics":["boilerplate","cypress","emotion","fetch","jest","next-seo","next-sitemap","nextjs","postcss","react","react-test-renderer","react-testing-library","storybook","swr","tailwindcss","typescript"],"latest_commit_sha":null,"homepage":"https://next-boilerplate-movahedan.vercel.app","language":"TypeScript","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/movahedan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-09-04T21:20:10.000Z","updated_at":"2023-11-30T06:55:19.000Z","dependencies_parsed_at":"2022-08-30T18:02:00.248Z","dependency_job_id":null,"html_url":"https://github.com/movahedan/next-boilerplate","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/movahedan%2Fnext-boilerplate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/movahedan%2Fnext-boilerplate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/movahedan%2Fnext-boilerplate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/movahedan%2Fnext-boilerplate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/movahedan","download_url":"https://codeload.github.com/movahedan/next-boilerplate/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249414252,"owners_count":21267724,"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":["boilerplate","cypress","emotion","fetch","jest","next-seo","next-sitemap","nextjs","postcss","react","react-test-renderer","react-testing-library","storybook","swr","tailwindcss","typescript"],"created_at":"2024-08-01T22:03:01.946Z","updated_at":"2026-02-03T08:30:56.920Z","avatar_url":"https://github.com/movahedan.png","language":"TypeScript","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"readme":"# Next.js opinionated boilerplate\n\nA well-structured production-ready Next.js boilerplate with a well-documented directory structuring that supports Typescript, Jest, react-testing-library, Cypress, configurable Fetch and SWR, and a configured component library using Emotion, twin.macro, Tailwind, and Storybook. Plus, taking advantage of NextSeo and NextSitemap. \n\n![Coverage Badge](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/movahedan/49ff7044879e43a1daf430086b622c53/raw/next-boilerplate__heads_main.json)\n![Build Badge](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/movahedan/49ff7044879e43a1daf430086b622c53/raw/next-boilerplate__build_badge.json)\n\n## Benefits\n\n### Project maintenance\n- [x] Setup strong Linter, lint-staged, husky\n- [x] Setup Jest and react-test-renderer\n- [x] Setup Cypress\n- [x] Setup GitHub actions\n- [x] Deploy on vercel\n- [x] Dockerize it\n### Application development\n- [x] Setup directory structure and global types [Read documentation](https://github.com/movahedan/next-boilerplate/blob/main/docs/directories.md \"Directories documentation\")\n- [x] Setup configurable Fetch and SWR\n- [x] Setup Analytics tools with separate business level abstracting [Read documentation](https://github.com/movahedan/next-boilerplate/blob/main/docs/analytics.md \"Analytics documentation\")\n- [x] Setup SEO optimization (NextSeo, NextSitemap)\n-\tSetup Error Handling and Reporting\n- Setup Redux\n### Styling\n- [x] Setup Emotion and twin.macro with fully-configured Tailwind\n- [x] Setup UI library (Storybook installed with some helper functions)\n-\t[x] Setup MediaQuery module (SSR support)\n- [x] Setup optimized, easy to change, testable Google font\n- [x] Setup Layout structure (Per page layout support)\n-\tImplement a minimal component library (with the help of headless ui)\n### Additional hooks\n  - [x] useAliveRef\n  - [x] useCombinedRef\n  - [x] useElementSize\n  - [x] useIntersect\n  - [x] useResizeEffect\n  - [x] useScrollEffect\n  - [x] useThrottleCallback\n  - [x] useThrottleEffect\n  - useInfiniteLoader\n  - useClipboard\n  - useLocalStorageState\n  - useCookieState\n  - useNetworkStatus\n### Additional components\n  - TruncatedText\n\n## Running\n\nAfter cloning repository, go to the directory you've cloned into.\n\n##### Run the development server\n```bash\nyarn dev\n```\nOpen [http://localhost:3000](http://localhost:3000) with your browser to see the result.\n\n##### Run the storybook\n```bash\nyarn storybook:dev\n```\nOpen [http://localhost:6006](http://localhost:6006) with your browser to see the result.\n\n##### Run the cypress\n```bash\nyarn cypress:dev\n```\n\n## Build and deploy\n\nTo check for a clean deployment and run the project run the following commands, they will take care of unit testing, e2e testing and create production-optimized build of application.\n\n```bash\nyarn deploy:test\nyarn deploy:e2e\nyarn start\n```\n\nTo build storybook, run the following command:\n```bash\nyarn storybook:build\n```\n\n## Contributing\n\nFist change the thing you with to be changed and check your staged changes status with the following command.\n```bash\nyarn commit-check\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmovahedan%2Fnext-boilerplate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmovahedan%2Fnext-boilerplate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmovahedan%2Fnext-boilerplate/lists"}