{"id":14984155,"url":"https://github.com/sanjaytwisk/nextjs-ts","last_synced_at":"2025-05-16T14:06:33.196Z","repository":{"id":42454728,"uuid":"176513961","full_name":"sanjaytwisk/nextjs-ts","owner":"sanjaytwisk","description":"Opinionated Next JS project boilerplate with TypeScript and Redux","archived":false,"fork":false,"pushed_at":"2025-01-07T13:10:10.000Z","size":4682,"stargazers_count":269,"open_issues_count":1,"forks_count":45,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-04-12T11:55:39.111Z","etag":null,"topics":["boilerplate","css-modules","husky","jest","linters","nextjs","prettier","react","redux","safety","scss","static-site","stylelint","svg-sprites","testing-library","typescript"],"latest_commit_sha":null,"homepage":"","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/sanjaytwisk.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":"2019-03-19T13:06:55.000Z","updated_at":"2025-03-28T10:18:47.000Z","dependencies_parsed_at":"2023-01-29T11:01:48.473Z","dependency_job_id":"3c079002-a460-4e41-b2f7-d8553fffad06","html_url":"https://github.com/sanjaytwisk/nextjs-ts","commit_stats":{"total_commits":95,"total_committers":6,"mean_commits":"15.833333333333334","dds":0.5157894736842106,"last_synced_commit":"d99caf9caa59c13c3d81fe3cc2df98f9940ead65"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanjaytwisk%2Fnextjs-ts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanjaytwisk%2Fnextjs-ts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanjaytwisk%2Fnextjs-ts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sanjaytwisk%2Fnextjs-ts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sanjaytwisk","download_url":"https://codeload.github.com/sanjaytwisk/nextjs-ts/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254544146,"owners_count":22088807,"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","css-modules","husky","jest","linters","nextjs","prettier","react","redux","safety","scss","static-site","stylelint","svg-sprites","testing-library","typescript"],"created_at":"2024-09-24T14:08:33.820Z","updated_at":"2025-05-16T14:06:33.177Z","avatar_url":"https://github.com/sanjaytwisk.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NextJS Boilerplate\n\nAn opinionated boilerplate to kickstart projects using NextJS\n\n**Features**\n\n- 👏🏼 Next 13\n- ⚛️ React 18\n- 🌊 Custom Document and App\n- ⌨️ Type safety using TypeScript in strict mode\n- 💄 Write SCSS \u0026 future CSS with PostCSS + preset-env\n- 🖊 SVG sprite for icons\n- 👀 Lint your code with ESLint \u0026 Stylelint\n- 🌈 Prettier for consistent code style\n- 🔨 Jest + [Testing Library](https://testing-library.com/) for tests\n- ☝️ Husky + lint-staged for code quality assurance\n- ⚙️ Editorconfig file for consistent indents\n- 🗄 Redux with `react-redux` and `redux-thunk`\n\n## Variation branches\n\n### [Custom server](https://github.com/sanjaytwisk/nextjs-ts/tree/custom-server)\n\n```sh\ngit clone -b custom-server --single-branch git@github.com:sanjaytwisk/nextjs-ts.git\n```\n\n### [Enzyme](https://github.com/sanjaytwisk/nextjs-ts/tree/enzyme)\n\n```sh\ngit clone -b enzyme --single-branch git@github.com:sanjaytwisk/nextjs-ts.git\n```\n\n### [No redux](https://github.com/sanjaytwisk/nextjs-ts/tree/no-redux)\n\n```sh\ngit clone -b no-redux --single-branch git@github.com:sanjaytwisk/nextjs-ts.git\n```\n\n## Getting started\n\nBefore you can start developing your awesome application you need to install the project's dependencies. Make sure you have Node (\u003e= 10.13.0) and NPM installed and run:\n\n```sh\n$ npm install\n```\n\n### ⌨️ Development\n\nOnce all dependencies have been installed you can start development. To start a development server on [http://localhost:3000](http://localhost:3000) run:\n\n```sh\n$ npm run dev\n```\n\n### 🖥 Production\n\nTo run your application in production make sure to run a build first:\n\n```sh\n$ npm run build\n```\n\nAnd then start you application with a provided port number (defaults to 3000 if not provided):\n\n```sh\n$ PORT=8080 npm run start\n```\n\n### 🖨 Static\n\nYou can export your application to a static website as well:\n\n```sh\nnpm run export\n```\n\nThis will render static HTML pages into `./out`\n\n### 🧐 Linters\n\nThe boilerplate provides a couple of linters to help you keep an eye on code consistency and type safety. There are three linters: one for CSS, one for TypeScript and one for type safety. You can use each of them separately using the following commands:\n\n```sh\n$ npm run lint:css\n$ npm run lint:ts\n$ npm run lint:types\n```\n\nTIP: To get the most out of your linters install the corresponding (Stylelint, TSLint) plugins for your editor or IDE\n\n**Prettier**\n\nPrettier helps you to enforce consistent (opinionated) code style. If possible, you can tell your editor to format you code when you save a file. If you are not able to do this, you can run prettier manually using:\n\n```sh\n$ npm run prettier\n```\n\n### 🤖 Tests\n\nYou can write your tests using Jest and Enzyme. You can run all test with the following command\n\n```sh\n$ npm run test\n```\n\nIf you want to follow test driven development you can use:\n\n```sh\n$ npm run test:dev\n```\n\n## Modules\n\n### TypeScript\n\nTypeScript and Babel are pre-configured with custom module resolvers.\nThis means you can use absolute imports with custom namespaces by default for the following modules:\n\n```js\n/* import common library */\nimport lib from '@common/\u003cfolder\u003e/\u003clib\u003e'\n/* import component */\nimport Counter from '@components/counter/Counter'\n/* import container */\nimport HomepageCounter from '@containers/counter/HomepageCounter'\n/* import store files */\nimport { CounterAction } from '@store/counter/counterActions'\n```\n\n### SCSS\n\nBy default the path `./src/common/css` is configured as an included path for our scss loader.\nThis means you can import any of this folder's files directly without the relative or absolute path:\n\n```css\n@import 'variables';\n@import 'colors';\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsanjaytwisk%2Fnextjs-ts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsanjaytwisk%2Fnextjs-ts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsanjaytwisk%2Fnextjs-ts/lists"}