-
Notifications
You must be signed in to change notification settings - Fork 53
RFC: how should we structure our monorepo and packages #433
Comments
|
|
It seems that we might want to separate the React packages from the vanilla/core packages as well. Slot / createSlotFactory, agree that we should publish something like this. I think we need to iterate that again before doing so though. Example issue, we call it "slot" but then we use it as the root |
Guys from Segment (/~https://github.com/segmentio/evergreen) have a similar primitive, they call it |
It might also make sense to have |
|
I was just talking this through with @davezuko as well. We're thinking we need to be careful to not over burden ourselves with package granularity. At the same time, we should consider how to divide packages on the most intuitive axis, like React vs core (vanilla) packages. Here's what we're proposing:
Repo StructureEach top-level directory represents a domain of concern. Each domain has a
Package APIWe would target this sort of package API surface:
Given the target packages, do we want to organize vanilla JS state/style/accessibility solutions under a |
I think the process you have outlined is a good way to go.
Yes to this ⏫
Definitely do this first. I found in our application architecture at Espressive that the work getting everything moved to packages and updating dependencies there was a significant amount of work. And in the process we discovered some things made sense to bundle into packages together. We also discovered having TOO many packages can actually start to slow down install performance (especially in Jenkins), though yarn has improved that in recent releases. Since it looks like we intend to publish core/react/themes to NPM, are we looking to utilize Lerna to help with that process? If there are only a few packages like this that will be published we might actually be able to get away with some more lightweight tooling for that. |
@levithomason I will suggest to add |
Removed |
We have most of this structured now. We're also going to share packages with other libraries in a common location. See our repo for the latest structure. |
We will move to a monorepo and publish packages for state, styling, and accessibility at the least. We also have utilities such as our factories, which may be part of a "core" package. What packages do we foresee and what modules should be included in them?
This list is updated per the discussion below:
@stardust-ui/prop-types
/lib/customPropTypes.tsx
/packages
@stardust-ui/auto-controlled-component
/lib/AutoControlledComponent.tsx
/packages
The text was updated successfully, but these errors were encountered: