question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Forma 36 4.0 Packages Structure

See original GitHub issue

Hey F36 Community 🖖

with Forma 36 4.0 approaching we suggest a new project structure that will change the way how we organize and publish react components.

Description

As you’re aware we currently manage all components in a single package forma-36-react-components which many times was challenging to us in terms of resulting bundle size and SLA’s (alpha components)

To offer more flexibility around component management we envision the future project structure like this.

Packages Structure

└── packages
    ├── components
    │   ├── forma-36-react-button
    │   ├── forma-36-react-dropdown
    │   └── forma-36-react-textfield
    ├── forma-36-fcss
    ├── forma-36-react-components
    ├── forma-36-tokens
    └── forma-36-website

The main difference is that every component will be its own package which means that every component will also be published separately. As I see it the main benefits of this structure are:

  1. Atomic imports. The consumer can import just the components they need and not the entire bundle.
  2. Independent component versioning
  3. Component-based SLA’s (alpha components, experimental components)

We’ll still keep the forma-36-react-components package as a facade package that imports all components, creates one bundle and also serves the storybook docs.

Any feedback is much appreciated!

Thanks ❤️

Johannes

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:5
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
suevalovcommented, Nov 5, 2019

Sounds good for me, with Lerna and tsdx it is actually quite sane approach and it will help to make extensions slimmer.

The only thing that I would do is to create one umbrella package to avoid importing all components one by one in our web app.

1reaction
wichniowskicommented, Nov 5, 2019

@davidfateh we’ll definitely have components that rely on each other but since we’re using Lerna those dependant components will be published and updated automatically. Using the forma-36-react-components package which imports all those components nothing should change meaning that it will release one new version no matter how many components changed. The only overhead I can see here is that when you’re using the components separately you’ll have to update all dependent components as you described.

Read more comments on GitHub >

github_iconTop Results From Across the Web

FAQ - Forma 36
Accelerated speed - V4 splits components into separate packages, meaning you can use those you need without adding the full suite to your...
Read more >
An inside peek at the development of Forma 36 v4 - Contentful
Now that Forma 36 version 4 is generally available, UI Engineer Patrycja ... In v4, we've split components into separate packages.
Read more >
Forma 36 - The Contentful Design System
Forma 36 is an open-source design system by Contentful created with the intent to reduce the overhead of creating UI by providing tools...
Read more >
What's new - Forma 36
The Changelog gives an overview of the changes we've made to Forma 36 ... F36 Multiselect v4.20.10 ... v4.20.6. Bump package to fix...
Read more >
Forma 36 v4 is in GA and ready for building - Contentful
Forma 36 is Contentful's open-source design system, created to help you easily extend the Contentful UI as you build apps and customize your ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found