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

chore: bump @svgr/* dependencies #1359

Merged
merged 4 commits into from
Mar 5, 2024

Conversation

chanceaclark
Copy link
Contributor

@chanceaclark chanceaclark commented Mar 5, 2024

What?

Bumps @svgr/* plugins and all the changes that come with it. This includes updating the build scripts, adding a custom SVGO plugin, and rebuilding all the icons. I will be leaving some comments on notable changes below.

Why?

Mostly to stop the annoying dependabot updates, but really to update to the latest.

Screenshots/Screen Recordings

screencapture-localhost-3000-icons-2024-03-05-10_40_39

Screenshot 2024-03-05 at 10 41 37

},
'removeXMLNS',
removeInkscapeAttrs,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is only used within flags as the third-party library we use doesn't strip these attributes out. TS wouldn't build the icons with these attributes left behind, as it's unknown to them and they are unnecessary to use.

Comment on lines +35 to +37

export const ${variables.componentName} = memo(createStyledFlagIcon(FlagIconWithForwardedRef));

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Eslint will get a majority of the spacing issues, but unfortunate to a newer babel plugin version, newlines will not be preserved. See gregberge/svgr#809

You'll notice this more in the rebuilt icons.

Comment on lines -21 to -22
import { PrivateIconProps } from '../../base';
import { createStyledFlagIcon, FlagIconProps } from '../base';
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Instead of having two imports, I just reexported the type from ../base

@chanceaclark chanceaclark changed the title Chore/bump svgr chore: bump @svgr/* dependencies Mar 5, 2024
@chanceaclark chanceaclark marked this pull request as ready for review March 5, 2024 15:44
@chanceaclark chanceaclark requested review from a team as code owners March 5, 2024 15:44
@chanceaclark chanceaclark merged commit 4281d7a into bigcommerce:main Mar 5, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants