Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rsmuthu/monorepo-template
This is a Monorepo template for react, node and normal javascript library components.
https://github.com/rsmuthu/monorepo-template
babel commitlint eslint jest lerna lerna-monorepo monorepo nodejs nx nyc react reactjs semver-release storybook stylelint verdaccio webpack webpack5
Last synced: 8 days ago
JSON representation
This is a Monorepo template for react, node and normal javascript library components.
- Host: GitHub
- URL: https://github.com/rsmuthu/monorepo-template
- Owner: RSMuthu
- License: mit
- Created: 2022-08-03T07:02:53.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2022-08-03T07:42:59.000Z (over 2 years ago)
- Last Synced: 2024-11-23T12:09:26.573Z (2 months ago)
- Topics: babel, commitlint, eslint, jest, lerna, lerna-monorepo, monorepo, nodejs, nx, nyc, react, reactjs, semver-release, storybook, stylelint, verdaccio, webpack, webpack5
- Language: JavaScript
- Homepage:
- Size: 232 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Monorepo Template
This is a monorepo template which holds library components built off react, plain js or nodejs.\
This is more of an accumulation of my few learning in past few weeks.\
All the common and dev dependencies are pulled out to the rootdir of monorepo to leverage those dependencies from the packages while few majors (like, react & react-dom) are set as peer-dependencies.\
Most necesary scripts have also been added along with the monorepo template to facilitate ci/cd workflows.
React peer dependencies are set to v17.0.2 and not the latest v18 as it would more amendment to my base templateRecommended Node version: v16.11+ (for es13 specification features)
#### Package Creation
Showing the images for react package creation alone. The other types of packages can be created in similar way.![Package creation](img/creation.png)
![Created Package Structure](img/packageStructure.png)
#### Features available in this template
- [lerna](https://lerna.js.org/) setup for monorepo & workspace management
- lerna task execution via [nx](https://nx.dev/) (for effective lerna task execution)
- [Babel](https://babeljs.io/) setup (for ecmascript)
- Linters ([eslint](https://eslint.org/) & [stylelint](https://stylelint.io/) - standard configs and few of my personal likings)
- unit testing [Jest](https://jestjs.io/) (setup on both package level and repo level)
- code coverage + threshold validation via [nyc](https://istanbul.js.org/) & [Jest](https://jestjs.io/)
- [Storybook](https://storybook.js.org/) for UI components (along with feature for attaching [figma](https://www.figma.com/) or adobe design)
- Custom package creation command for this monorepo template.
- [Webpack5](https://webpack.js.org/) bundler made to handle different scenarios of packages
- [semver](https://semver.org/) versioning through version bump based on commit message
- commit message enforced via [commitlint](https://commitlint.js.org/) to conventional commit standards
- Git hooks setup via [husky](https://typicode.github.io/husky/) (pre-commit & commit-msg)
- Basic Proxy registry (along with uplink) setup with [verdaccio](https://verdaccio.org/)#### Future plans
- Update react to latest v18 for its latest features
- add Vuejs compatibility to this monorepo template
- add a custom storybook framework for supporting both vuejs & reactjs together on storybook bundling
- add clean github workflows to the monorepo template