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

[LOOM-1377]: transform to mjs & replace svg2react with svgr #71

Merged
merged 9 commits into from
Apr 25, 2024

Conversation

mungodewar
Copy link
Contributor

@mungodewar mungodewar commented Apr 15, 2024

Task

  • Transform to mjs
  • Replace svg2react with svgr
  • Created components are now .jsx not .js
  • Created components how have .d.ts typings files

@mungodewar mungodewar added the major Used for major changes label Apr 15, 2024
@xalechez
Copy link
Contributor

Looks great! I guess the only thing missing is transpliation of tsx icons

@mungodewar
Copy link
Contributor Author

Looks great! I guess the only thing missing is transpliation of tsx icons

I was considering that this would be handled by bpk, as the dist get's cp'd into the repo. https://github.com/Skyscanner/backpack/blob/main/gulpfile.js/bpk-component-icon/gulpfile.babel.js

Not ideal, however, if/when we wanted to remove that weirdness we can tackle transpilation at that point. Or do you think that is a bit dangerous?

@xalechez
Copy link
Contributor

I'd rather go safe and not publish tsx to npm, in case someone is using this library directly (which can always be the case with OSS)

@mungodewar
Copy link
Contributor Author

I'd rather go safe and not publish tsx to npm, in case someone is using this library directly (which can always be the case with OSS)

Yup, that's fair.

@metalix2
Copy link
Contributor

I think it looks good though is it worth updating/adding to the readme the process that happens to generate these svg components and how to manage their transformation with the svgr build file? Just for the next person to know how all this works.

Copy link
Contributor

@metalix2 metalix2 left a comment

Choose a reason for hiding this comment

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

Love it!

@mungodewar mungodewar merged commit 73068f6 into main Apr 25, 2024
3 checks passed
@mungodewar mungodewar deleted the loom-1377 branch April 25, 2024 14:21
@mungodewar mungodewar added minor Used for minor changes and removed major Used for major changes labels Apr 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
minor Used for minor changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants