Code Monkey home page Code Monkey logo

wayofdev / next-starter-tpl Goto Github PK

View Code? Open in Web Editor NEW
58.0 1.0 8.0 4.6 MB

πŸ€– This is a microservices-ready template for building Next.js applications, used by Wayofdev. It comes bundled with Turbo and is managed as a monorepo using PNPM

Home Page: https://next-starter-tpl-docs.wayof.dev

License: MIT License

JavaScript 25.05% TypeScript 45.44% Shell 0.49% Makefile 5.16% CSS 1.05% HTML 0.03% MDX 22.77%
boilerplate nextjs pnpm pnpm-workspace turborepo docker docker-compose jest microservice typescript

next-starter-tpl's Introduction






NextJS Starter Template

πŸ“„ About

This repository contains a monorepo boilerplate written in Next.js, managed by the pnpm package manager.

You can use it with the backend template, written in Laravel β€” laravel-starter-tpl.

β†’ Purpose

  • Establish a clear structure and present a lifecycle perspective (developer experience, continuous integration/continuous deployment, and deployments);
  • Demonstrate how to create and consume shared packages, locales, assets, and API types;
  • Provide a fully configured repository with integrated tools and configs, such as tsconfig, eslint, jest, cypress, tailwind, changelogs, versioning, codecov, codeclimate, sentry, and others;
  • Clarify advantages of using a monorepo, such as team cohesion, consistency, duplication, refactorings, and atomic commits.

β†’ Utilities and Features

This repository has some additional tools already setup for you:


πŸ™ If you find this repository useful, please consider giving it a ⭐️. Thank you!


πŸ€” What's inside?

Open in Gitpod

This turborepo uses pnpm as a package manager. It includes the following packages/apps:

β†’ Structure

.
β”œβ”€β”€ apps
β”‚   β”œβ”€β”€ web                  # Next.js app - i18n, SSR, API, Jest, Cypress
β”‚   └── docs                 # Nextra app
└── packages
    β”œβ”€β”€ common-i18n          # Locales...
    β”œβ”€β”€ facebook-pixel       # Facebook Pixel tracking functionality
    β”œβ”€β”€ google-tag-manager   # Google Tag Manager functionality
    └── ui                   # React stub components

β†’ Apps

Application URL Description
docs Demo Nextra documentation template generated from Nextra: Docs Starter Kit
web Demo Next.js app with TailwindCSS, Facebook Pixel and Google Tag Manager tracking, and Sentry support
storybook Demo Storybook β€” UI component explorer for React components

Note: Apps should not depend on apps, they can depend on packages

β†’ Packages

Package Docs Description
common-i18n README.md Locales for multi-language support
facebook-pixel README.md Facebook Pixel tracking functionality
google-tag-manager README.md Google Tag Manager functionality
ui README.md Shared react stub components

Note: Apps can depend on packages, packages can depend on each others


🚩 Requirements

To use this repository, you need to meet the following requirements:


πŸ’Ώ Installation and Usage

Warning: You should configure, set up, and run the docker-shared-services repository to ensure system-wide TLS and DNS support.

Follow getting-started guide in documentation πŸ”—


🀝 License

Licence

FOSSA Status


🧱 Credits and Useful Resources

This repository is based on the nextjs-monorepo-example template from belgattitude.

Learn more about the power of Turborepo:

Here are some other monorepo templates you may find useful:

Other projects:


πŸ™†πŸΌβ€β™‚οΈ Author Information

This repository was created in 2022 by lotyp / wayofdev.


πŸ™Œ Want to Contribute?

Thank you for considering contributing to the wayofdev community! We are open to all kinds of contributions. If you want to:

  • πŸ€” Suggest a feature
  • πŸ› Report an issue
  • πŸ“– Improve documentation
  • πŸ‘¨β€πŸ’» Contribute to the code

You are more than welcome. Before contributing, kindly check our guidelines.


🫑 Contributors

Contributors

Contributors

πŸ€‘ Sponsors

Reproto Logo
Reproto

πŸŽ–οΈ Financial Support
VarsityBase Logo
VarsityBase

πŸŽ–οΈ Financial Support
Vercel Logo
Vercel

☁️ Infrastructure Support
Sentry Logo
Sentry

☁️ Infrastructure Support
ZenHub Logo
ZenHub

☁️ Infrastructure Support

next-starter-tpl's People

Contributors

dependabot[bot] avatar fossabot avatar github-actions[bot] avatar lotyp avatar renovate[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

next-starter-tpl's Issues

Add environment variables to documentation

Show, what env variables should be added when deploying to Vercel

NEXT_PUBLIC_GTM_ID
NEXT_DISABLE_SENTRY
NEXTAUTH_URL
SENTRY_URL
SENTRY_ORG
SENTRY_PROJECT
SENTRY_AUTH_TOKEN
NEXT_SENTRY_TRACING
NEXT_SENTRY_DEBUG

ERR_PNPM_LINKING_FAILED

Hello,

first of all, great job, I have macOS with m2 I tried to test the app but I have this error :

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 ERR_PNPM_LINKING_FAILED  Error: ENOENT: no such file or directory, copyfile '/app/.pnpm-store/v3/files/d6/4e80510e4d851c71247d6dd4c74576f88513beed85f8e942f5ed1aaba02ece2d9a53564923ab5d1b23a4587f6576d6df7e2db1f519cd467b7d89e4792ea2dd' -> '/app/node_modules/.pnpm/[email protected]/node_modules/es-abstract_tmp_1/2019/CompletePropertyDescriptor.js'
Progress: resolved 2268, reused 2209, downloaded 0, added 77
make: *** [i] Error 1

any idea ?

regards

Things to do:

  • Update to latest deps
  • Update to app router
  • Add admin template
  • Move from keycloak to auth0 (Move code from closes source project)
  • Storybook should use nextjs instead of vite
  • Improve gh actions and move them to wayofdev/gh-actions
  • Update underlying WOD packages
  • More examples for UI
  • Connect with wayofdev/laravel-cycle-starter-tpl to show usage of API

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update actions/checkout digest to 0ad4b8f
  • chore(deps): update dependency @types/facebook-pixel to v0.0.31
  • chore(deps): update dependency @types/shell-quote to v1.7.5
  • chore(deps): update dependency @wayofdev/browserslist-config to v3.0.4
  • chore(deps): update dependency @wayofdev/commitlint-config to v3.0.5
  • chore(deps): update dependency @wayofdev/eslint-config-bases to v3.0.7
  • chore(deps): update dependency @wayofdev/markdownlint-config to v3.0.3
  • chore(deps): update dependency @wayofdev/secretlint-config to v3.0.5
  • chore(deps): update dependency @wayofdev/tsconfig-config to v3.0.3
  • chore(deps): update dependency autoprefixer to v10.4.19
  • chore(deps): update dependency autoprefixer to v10.4.19
  • chore(deps): update dependency get-tsconfig to v4.7.3
  • chore(deps): update dependency lint-staged to v14.0.1
  • chore(deps): update dependency postcss to v8.4.38
  • chore(deps): update dependency rimraf to v5.0.5
  • chore(deps): update dependency sharp to v0.33.3
  • chore(deps): update dependency tailwindcss to v3.4.3
  • chore(deps): update dependency vite to v4.5.3
  • chore(deps): update pnpm to v8.15.8
  • chore(deps): update storybook monorepo to v7.6.19 (@storybook/addon-essentials, @storybook/addon-interactions, @storybook/addon-links, @storybook/addon-viewport, @storybook/blocks, @storybook/cli, @storybook/react, @storybook/react-vite, storybook)
  • fix(deps): update dependency @headlessui/react to v1.7.19
  • fix(deps): update dependency @swc/helpers to v0.5.11
  • fix(deps): update dependency clsx to v2.1.1
  • fix(deps): update dependency next-auth to v4.24.7
  • fix(deps): update fontsource monorepo to v5.0.18 (@fontsource-variable/inter, @fontsource/inter)
  • fix(deps): update nextra monorepo to v2.13.4 (nextra, nextra-theme-docs)
  • chore(deps): update dependency @playwright/test to v1.43.1
  • chore(deps): update dependency @testing-library/react to v14.3.1
  • chore(deps): update dependency @types/node to v20.12.8
  • chore(deps): update dependency @types/node to v20.12.8
  • chore(deps): update dependency @types/react-test-renderer to v18.3.0
  • chore(deps): update dependency @wayofdev/lint-staged-config to v2.2.0
  • chore(deps): update dependency browserslist to v4.23.0
  • chore(deps): update dependency css-loader to v6.11.0
  • chore(deps): update dependency cssnano to v6.1.2
  • chore(deps): update dependency eslint to v8.57.0
  • chore(deps): update dependency eslint to v8.57.0
  • chore(deps): update dependency markdownlint to ^0.34.0
  • chore(deps): update dependency markdownlint-cli to ^0.40.0
  • chore(deps): update dependency postcss-preset-env to v9.5.9
  • chore(deps): update dependency prettier to v3.2.5
  • chore(deps): update dependency secretlint to v7.2.0
  • chore(deps): update dependency sort-package-json to v2.10.0
  • chore(deps): update dependency turbo to v1.13.3
  • chore(deps): update dependency typescript to v5.4.5
  • chore(deps): update dependency typescript to v5.4.5
  • chore(deps): update react monorepo (@types/react, @types/react-dom, react, react-dom, react-test-renderer)
  • fix(deps): update dependency @vercel/analytics to v1.2.2
  • fix(deps): update dependency i18next to v23.11.3
  • fix(deps): update dependency next-seo to v6.5.0
  • fix(deps): update dependency react-hook-form to v7.51.3
  • fix(deps): update dependency type-fest to v4.18.1
  • fix(deps): update dependency zod to v3.23.5
  • chore(deps): update dependency @commitlint/cli to v19
  • chore(deps): update dependency @types/testing-library__jest-dom to v6
  • chore(deps): update dependency @wayofdev/eslint-config-bases to v4
  • chore(deps): update dependency @wayofdev/markdownlint-config to v4
  • chore(deps): update dependency @wayofdev/postcss-config to v4
  • chore(deps): update dependency @wayofdev/secretlint-config to v4
  • chore(deps): update dependency @wayofdev/tsconfig-config to v4
  • chore(deps): update dependency css-loader to v7
  • chore(deps): update dependency cssnano to v7
  • chore(deps): update dependency eslint to v9
  • chore(deps): update dependency husky to v9
  • chore(deps): update dependency lint-staged to v15
  • chore(deps): update dependency npm-run-all2 to v6
  • chore(deps): update dependency postcss-cli to v11
  • chore(deps): update dependency postcss-import to v16
  • chore(deps): update dependency prettier to v3.2.5 (prettier, @types/prettier)
  • chore(deps): update dependency secretlint to v8
  • chore(deps): update dependency size-limit to v11
  • chore(deps): update dependency style-loader to v4
  • chore(deps): update dependency tsup to v8
  • chore(deps): update dependency vite to v5
  • chore(deps): update felixmosh/turborepo-gh-artifacts action to v3
  • chore(deps): update nextjs monorepo to v14 (major) (@next/bundle-analyzer, @next/env, eslint-config-next, next)
  • chore(deps): update pnpm to v9
  • chore(deps): update storybook monorepo to v8 (major) (@storybook/addon-essentials, @storybook/addon-interactions, @storybook/addon-links, @storybook/addon-viewport, @storybook/blocks, @storybook/cli, @storybook/react, @storybook/react-vite, storybook)
  • chore(deps): update testing-library monorepo (major) (@testing-library/dom, @testing-library/jest-dom, @testing-library/react)
  • fix(deps): update dependency @httpx/exception to v3
  • fix(deps): update dependency next-i18next to v15
  • fix(deps): update dependency react-i18next to v14
  • πŸ” Create all rate-limited PRs at once πŸ”

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

docker-compose
docker-compose.yaml
github-actions
.github/workflows/apply-labels.yml
.github/workflows/ci-apps-docs.yml
  • actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
  • actions/setup-node v4
  • felixmosh/turborepo-gh-artifacts v2
  • actions/cache v4
.github/workflows/ci-apps-web.yml
  • actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
  • actions/setup-node v4
  • felixmosh/turborepo-gh-artifacts v2
  • actions/cache v4
  • codecov/codecov-action v4
.github/workflows/ci-packages.yml
  • actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
  • actions/setup-node v4
  • felixmosh/turborepo-gh-artifacts v2
  • actions/cache v4
.github/workflows/create-arch-diagram.yml
.github/workflows/create-changesets-release.yml
.github/workflows/e2e-apps-web.yml
  • actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
  • actions/setup-node v4
  • felixmosh/turborepo-gh-artifacts v2
  • actions/cache v4
  • BerniWittmann/background-server-action v1
  • actions/upload-artifact v4
.github/workflows/shellcheck.yml
npm
apps/docs/package.json
  • @vercel/analytics 1.1.2
  • next 13.4.19
  • nextra 2.13.3
  • nextra-theme-docs 2.13.3
  • react 18.2.0
  • react-dom 18.2.0
  • @types/node 20.11.16
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • @wayofdev/eslint-config-bases 3.0.1
  • es-check 7.1.1
  • eslint 8.56.0
  • sharp 0.33.2
  • typescript 5.3.3
apps/storybook/package.json
  • react ^18.2.0
  • react-dom ^18.2.0
  • @storybook/addon-essentials 7.6.12
  • @storybook/addon-interactions 7.6.12
  • @storybook/addon-links 7.6.12
  • @storybook/addon-postcss 2.0.0
  • @storybook/addon-viewport ^7.0.0-rc.5
  • @storybook/blocks 7.6.12
  • @storybook/cli ^7.0.0-rc.5
  • @storybook/react 7.6.12
  • @storybook/react-vite 7.6.12
  • @storybook/testing-library 0.2.2
  • @tailwindcss/aspect-ratio ^0.4.2
  • @tailwindcss/forms ^0.5.4
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • @vitejs/plugin-react-swc 3.6.0
  • @wayofdev/eslint-config-bases 3.0.1
  • @wayofdev/postcss-config 3.0.2
  • autoprefixer ^10.4.14
  • eslint 8.56.0
  • postcss 8.4.33
  • postcss-100vh-fix 1.0.2
  • postcss-cli 10.1.0
  • postcss-flexbugs-fixes 5.0.2
  • postcss-normalize 10.0.1
  • postcss-preset-env 9.3.0
  • postcss-reporter 7.1.0
  • storybook 7.6.12
  • tailwindcss 3.4.1
  • typescript 5.3.3
  • vite 4.5.2
apps/web/package.json
  • @fontsource-variable/inter ^5.0.5
  • @fontsource/inter 5.0.16
  • @heroicons/react 2.1.3
  • @hookform/resolvers 3.3.4
  • @httpx/exception 2.6.4
  • @soluble/cache-interop ^0.12.8
  • @soluble/cache-ioredis ^0.13.11
  • @soluble/dsn-parser ^1.9.2
  • @vercel/analytics 1.1.2
  • @wayofdev/lint-staged-config 2.1.2
  • clsx 2.1.0
  • i18next 23.8.2
  • next 13.4.19
  • next-auth 4.24.5
  • next-i18next 14.0.3
  • next-secure-headers ^2.2.0
  • next-seo 6.4.0
  • next-sitemap 4.2.3
  • react 18.2.0
  • react-dom 18.2.0
  • react-hook-form 7.50.0
  • react-i18next 13.5.0
  • type-fest 4.10.2
  • zod 3.22.4
  • @next/bundle-analyzer 13.4.19
  • @next/env 13.4.19
  • @playwright/test 1.41.2
  • @sentry/nextjs 7.69.0
  • @size-limit/file 8.2.6
  • @tailwindcss/aspect-ratio 0.4.2
  • @tailwindcss/forms 0.5.7
  • @testing-library/dom 9.3.4
  • @testing-library/jest-dom 5.17.0
  • @testing-library/react 14.2.1
  • @testing-library/user-event 14.5.2
  • @types/facebook-pixel 0.0.30
  • @types/hoist-non-react-statics 3.3.5
  • @types/jest 29.5.12
  • @types/node 20.11.16
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • @types/react-test-renderer 18.0.7
  • @types/testing-library__jest-dom 5.14.9
  • @wayofdev/eslint-config-bases 3.0.1
  • @wayofdev/postcss-config 3.0.2
  • autoprefixer 10.4.17
  • css-loader 6.10.0
  • cssnano 6.0.3
  • es-check 7.1.1
  • eslint 8.56.0
  • eslint-config-next 13.4.19
  • get-tsconfig 4.7.2
  • jest 29.7.0
  • jest-css-modules-transform 4.4.2
  • jest-environment-jsdom 29.7.0
  • picocolors 1.0.0
  • postcss 8.4.33
  • postcss-100vh-fix 1.0.2
  • postcss-flexbugs-fixes 5.0.2
  • postcss-import 15.1.0
  • postcss-preset-env 9.3.0
  • postcss-reporter 7.1.0
  • react-test-renderer 18.2.0
  • sanitize.css 13.0.0
  • size-limit 8.2.6
  • style-loader 3.3.4
  • tailwindcss 3.4.1
  • ts-jest 29.1.2
  • tslib 2.6.2
  • typescript 5.3.3
package.json
  • @changesets/changelog-github ^0.5.0
  • @changesets/cli 2.27.1
  • @commitlint/cli ^18.0.0
  • @types/node ^20.4.2
  • @types/prettier ^2.7.3
  • @types/shell-quote ^1.7.1
  • @wayofdev/browserslist-config ^3.0.1
  • @wayofdev/commitlint-config ^3.0.1
  • @wayofdev/eslint-config-bases ^3.0.2
  • @wayofdev/lint-staged-config ^2.1.1
  • @wayofdev/markdownlint-config ^3.0.1
  • @wayofdev/secretlint-config ^3.0.1
  • @wayofdev/tsconfig-config ^3.0.1
  • browserslist ^4.21.9
  • eslint ^8.45.0
  • husky ^8.0.3
  • is-ci ^3.0.1
  • lint-staged ^14.0.0
  • markdownlint ^0.33.0
  • markdownlint-cli ^0.39.0
  • npm-run-all2 ^5.0.0
  • prettier ^3.0.0
  • rimraf ^5.0.1
  • secretlint ^7.0.3
  • shell-quote ^1.8.1
  • sort-package-json ^2.5.1
  • turbo ^1.10.7
  • typescript ^5.1.6
  • node >=18.0.0
  • pnpm 8.15.1
packages/common-i18n/package.json
  • @types/jest 29.5.12
  • @types/node 20.11.16
  • @wayofdev/eslint-config-bases 3.0.1
  • eslint 8.56.0
  • prettier 3.2.4
  • rimraf 5.0.5
  • typescript 5.3.3
packages/facebook-pixel/package.json
  • @types/facebook-pixel 0.0.30
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • @wayofdev/eslint-config-bases 3.0.1
  • next 13.4.19
  • react 18.2.0
  • react-dom 18.2.0
packages/google-tag-manager/package.json
  • @types/gapi.client.tagmanager 2.0.4
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • @wayofdev/eslint-config-bases 3.0.1
  • next 13.4.19
  • react 18.2.0
  • react-dom 18.2.0
packages/ui/package.json
  • @headlessui/react ^1.7.15
  • @heroicons/react 2.1.3
  • @swc/helpers 0.5.3
  • clsx 2.1.0
  • @tailwindcss/aspect-ratio 0.4.2
  • @tailwindcss/forms 0.5.7
  • @tailwindcss/line-clamp 0.4.4
  • @tailwindcss/typography 0.5.10
  • @testing-library/jest-dom 5.17.0
  • @testing-library/react 14.2.1
  • @types/jest 29.5.12
  • @types/node 20.11.16
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • @types/react-test-renderer 18.0.7
  • @wayofdev/eslint-config-bases 3.0.1
  • @wayofdev/lint-staged-config 2.1.2
  • @wayofdev/postcss-config 3.0.2
  • eslint 8.56.0
  • jest 29.7.0
  • jest-environment-jsdom 29.7.0
  • postcss 8.4.33
  • postcss-100vh-fix 1.0.2
  • postcss-flexbugs-fixes 5.0.2
  • postcss-import 15.1.0
  • postcss-preset-env 9.3.0
  • postcss-reporter 7.1.0
  • react 18.2.0
  • react-dom 18.2.0
  • react-test-renderer 18.2.0
  • rimraf 5.0.5
  • tailwindcss 3.4.1
  • ts-jest 29.1.2
  • tsup 7.2.0
  • typescript 5.3.3
  • @heroicons/react 2.1.3
  • @types/react 18.2.52
  • @types/react-dom 18.2.18
  • next *
  • react 18.2
  • react-dom 18.2

  • Check this box to trigger a request for Renovate to run again on this repository

Bundle analyzer does not opens browser, if running from docker

When executing the pnpm analyze command through Docker, the report is generated but the browser does not open automatically. This issue makes it difficult for users to view the report easily.

Expected Behavior:

The pnpm analyze command should generate the report and open the default browser to show it when executed through Docker.

Steps to Reproduce:

Run pnpm analyze command in a Docker container.
Check if the report is generated and saved.
Check if the browser opens to display the report.

Suggested Solution:

Modify the Docker container to automatically open the browser when the pnpm analyze command is executed.

Tasks:

Update the Dockerfile to include the necessary browser package.
Modify the command that executes pnpm analyze to automatically open the browser after generating the report.
Test the changes to ensure that the browser opens successfully and displays the report.

Optional:

Document the changes made in the README file of the repository to help other contributors.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.