base-ui
base-ui copied to clipboard
[infra] Extract utilities to a separate package
Extracted utilities that can be used in other MUI projects to a separate library - @base-ui-components/utils.
Before we start using it across the company, I want to update JSDocs and possibly rename and reorganize few utilities.
Bundle size report
| Bundle | Parsed Size | Gzip Size |
|---|---|---|
| @base-ui-components/react | ▼-295B(-0.10%) | ▼-124B(-0.13%) |
Generated by :no_entry_sign: dangerJS against c4c063ac2700c85bfe344a633aa2c984be24a81a
can be used in other MUI projects to a separate library
That means they will be semver stable? Should we document them?
cc @romgrk to get your attention on this PR, I believe you brought up the topic of shared libraries recently.
npm i https://pkg.pr.new/@base-ui-components/react@2167
npm i https://pkg.pr.new/@base-ui-components/utils@2167
commit: c4c063a
Deploy Preview for base-ui ready!
| Name | Link |
|---|---|
| Latest commit | c4c063ac2700c85bfe344a633aa2c984be24a81a |
| Latest deploy log | https://app.netlify.com/projects/base-ui/deploys/6870c96a87c30f00088628cc |
| Deploy Preview | https://deploy-preview-2167--base-ui.netlify.app |
| Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify project configuration.
Tested the release process and uploaded https://www.npmjs.com/package/@base-ui-components/utils
Have you considered exporting useButton hook? 🤔
We might actually have a Button component at some point, but it's not fully decided yet.
If you need to add button functions to a non-interactive component, I suppose useButton could be useful. However, before we export it, I'd like to clean it up properly and remove handling of HTML anchors (we could have useLink if there's a need, but I don't see it now).