Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Layout] Extract layout to separated package #466

Closed
michaltaberski opened this issue Apr 19, 2024 · 5 comments
Closed

[Layout] Extract layout to separated package #466

michaltaberski opened this issue Apr 19, 2024 · 5 comments
Labels
request New feature or request

Comments

@michaltaberski
Copy link

Layout components are very handy and can serve a nice building blocks for DesignSystems without styling. Did you consider to move the Layout set of utils to a separated package? Perhaps to package under primitives?

@kevinmitch14
Copy link

@michaltaberski
Copy link
Author

Yes, I have seen this. However installing the whole framework in order to use few utils from it it's quite an overhead, isn't it?

@vladmoroz
Copy link
Contributor

vladmoroz commented Apr 20, 2024

We don't plan to extract layout into a separate package. It's integrated tightly into the rest of the library so it would be a significant lift to do that and maintain the two together, which would require time better spent elsewhere.

What bothers you about the suggested approach? There's no "overhead" if your dev tooling can tree-shake the unused parts of the library, which is what most bundlers do today out of the box.

@vladmoroz vladmoroz added the request New feature or request label Apr 20, 2024
@vladmoroz vladmoroz closed this as not planned Won't fix, can't repro, duplicate, stale Apr 20, 2024
@michaltaberski
Copy link
Author

Yes, I have checked the source code and I have noticed it's quite a bit of work to extract layout from the repo.

Regarding what's bothering with using the entire radix-ui is not the bundle side grow, but rather additional set of dependencies added only due to the layout utils.

Anyway, thanks for an explenation 👍

@vladmoroz
Copy link
Contributor

If you are building a design system and want to include the layout components, Radix Themes dependencies won't affect anything if you set up the build process to tree-shake the unused components.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
request New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants