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

Codemod to convert from clsx or classnames to classix #31

Open
charkour opened this issue Sep 9, 2022 · 6 comments
Open

Codemod to convert from clsx or classnames to classix #31

charkour opened this issue Sep 9, 2022 · 6 comments

Comments

@charkour
Copy link

charkour commented Sep 9, 2022

First, thank you for creating and maintaining this package! It is great.

For devs currently utilizing clsx or classnames, do you have a suggested way to move from those to classix? Perhaps we could create a codemod to do that for devs looking to migrate. I looked through the readme and discussions and was not able to find best practices to make the switch.

Thanks!

@alexnault
Copy link
Owner

Hey @charkour! Thanks a lot!

I think it's a good idea. I'll add a "Moving to classix" section in the readme.

I don't have experience with writing codemods though. I could look into it but maybe someone with more experience would want to jump in?

@charkour
Copy link
Author

Thanks for the follow up! I think adding a readme section would be great.

A code mod would be a nice to have request. I haven't any experience writing either. I won't commit to it now, but will let you know if I start working on it.

Thanks!

@alexnault
Copy link
Owner

alexnault commented Sep 14, 2022

@charkour I've created this PR for the migration instructions. Let me know what you think!

@alexnault
Copy link
Owner

I'm leaving the issue open for a potential codemod :)

@charkour
Copy link
Author

Roger, thanks! I'm not planning on making it, but will let you know if I do! Would be awesome to have.

@charkour
Copy link
Author

charkour commented Sep 17, 2022

I spent some time working on a simple codemod. Not sure if/when I'll finish it, but wanted to link it here just in case people would like to help!

Using ASTexplorer.net to build the code mod.

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

No branches or pull requests

2 participants