Help with monorepo
See original GitHub issuehey,
i want to setup a monorepo (lerna) with vite and vue3 and i can´t find any working solutions. The main problem is to consume the local repos in development and benefit from vites fast hot-reloading and all the other sugar it gives to us. I played with optimizeDeps.link and rollup alias but cannot figure out an acceptable setup without hacky parts.
Can anyone please give an example how this is done right?
My folder structure looks like this:
project-root/
lerna.json
packages/
example-ui/
index.html
vite.config.ts
....
ui/
modules/
common/
src/comp.vue
package.json
dashboard/
src/dashboard.vue
package.json
.../
THX for the great work!
Issue Analytics
- State:
- Created 3 years ago
- Comments:14 (6 by maintainers)
Top Results From Across the Web
What is monorepo? (and should you use it?) - Semaphore CI
A monorepo, on the other hand, works as a central hub, a market square where every developer, engineer, tester, and business analyst meet...
Read more >Benefits and challenges of monorepo development practices
In a single, monolithic repository, also known as a monorepo, you keep all your application and microservice code in the same source code ......
Read more >Monorepo Explained
Monorepos are hot right now, especially among Web developers. We created this resource to help developers understand what monorepos are , what benefits...
Read more >11 Great Tools for a Monorepo in 2021 | Bits and Pieces
Workspaces helps with a few issues, making it a great monorepo setup: It sets up a single node_modules without repetitions or cloning dependencies...
Read more >A Guide to Monorepos for Front-end Code - Toptal
A monorepo or monorepository is a code management and architectural concept whereby you keep all your isolated bits of code inside one super...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
RFC
Hello guys, i’m coming to this thread referenced from #1554 where @yyx990803 call my attention to here. Would be great a cli tool to produce multi apps/libs and keep compatibility with vite-cli. Current i’m doing some research and prototyping with vite. Instead of using lerna (nothing against it, pretty good tool) but i would like to enrich vue/vite ecosystem with a tool more or less like nx.dev does to angular. I will leave here a idea spec for further discussion. This approach have some history (long a bit) that what i saw in many companies that follow lerna approach for multi vue apps and most of them regret on that decision.
optimizeDeps.link
package.json
, you will need to configure an alias in the example project to redirect to their source entry instead.We should probably provide some documentation for this. /cc @LinusBorg @csr632 @AlexandreBonaventure who I know have been using Vite in monorepos