Skip to content

[internal] Remove unnecessary packageName attribute from pages#33488

Merged
oliviertassinari merged 1 commit intomui:masterfrom
cherniavskii:remove-unnecessary-packageName
Aug 5, 2022
Merged

[internal] Remove unnecessary packageName attribute from pages#33488
oliviertassinari merged 1 commit intomui:masterfrom
cherniavskii:remove-unnecessary-packageName

Conversation

@cherniavskii
Copy link
Member

@cherniavskii cherniavskii commented Jul 12, 2022

Follow up on #33439
Since ComponentLinkHeader now has default packageName for each product, it's safe to remove most of packageName usage in pages:

const defaultPackageNames = {
'material-ui': '@mui/material',
'joy-ui': '@mui/joy',
base: '@mui/base',
system: '@mui/system',
};

Now packageName in only used on few pages that need to override it (@mui/lab and @mui/icons-material in material-ui product)

https://deploy-preview-33488--material-ui.netlify.app/base/react-badge/

@cherniavskii cherniavskii added the internal Behind-the-scenes enhancement. Formerly called “core”. label Jul 12, 2022
@@ -1,9 +1,8 @@
---
product: material-ui
product: base
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some pages like this one had outdated product attribute

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like these are all in the translated pages, which we don't generally edit directly. (I'm not sure why exactly.)

Copy link
Member

@oliviertassinari oliviertassinari Jul 15, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure why exactly.

https://www.notion.so/mui-org/Translations-1c9ad92060cb4bb49669ab5e1c0bbb8e: tries to answer this question.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So it looks like Crowdin will update product field as well, but only when there's an update to this page's translation.
If I understand it correctly, there should be no problem with updating it manually in this PR.

@mui-bot
Copy link

mui-bot commented Jul 12, 2022

No bundle size changes

Generated by 🚫 dangerJS against 4000b48

@oliviertassinari oliviertassinari added the docs Improvements or additions to the documentation. label Jul 15, 2022
@oliviertassinari oliviertassinari merged commit fbea1e1 into mui:master Aug 5, 2022
@oliviertassinari
Copy link
Member

@cherniavskii Great, thanks!

@cherniavskii cherniavskii deleted the remove-unnecessary-packageName branch August 6, 2022 09:30
daniel-rabe pushed a commit to daniel-rabe/material-ui that referenced this pull request Nov 29, 2022
@oliviertassinari oliviertassinari changed the title [core] Remove unnecessary packageName attribute from pages [internal] Remove unnecessary packageName attribute from pages Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to the documentation. internal Behind-the-scenes enhancement. Formerly called “core”.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants