https://github.com/fourcube/nextjs-babel-yarn-workspaces
Example for using a monorepo layout with NextJS, babel and yarn workspaces.
https://github.com/fourcube/nextjs-babel-yarn-workspaces
Last synced: 4 months ago
JSON representation
Example for using a monorepo layout with NextJS, babel and yarn workspaces.
- Host: GitHub
- URL: https://github.com/fourcube/nextjs-babel-yarn-workspaces
- Owner: fourcube
- Created: 2020-02-20T13:36:54.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-07T15:03:43.000Z (over 2 years ago)
- Last Synced: 2025-01-16T21:52:49.565Z (6 months ago)
- Language: JavaScript
- Size: 1.4 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Next.js + Babel Monorepo
To run this:
`yarn`
`yarn --cwd web dev`## Keypoints that make this work
`web/next.config.js` points to the root `babel.config.js`. For all sibling modules it forces `babel-loader` to use `rootMode: "upward"` so the modules discover the root `babel.config.js`. All babel configuration is hoisted into the root `babel.config.js` by providing `overrides` for each module.