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

Merging this codemod into eslint-plugin-testing-library #8

Open
Belco90 opened this issue Jan 19, 2022 · 3 comments
Open

Merging this codemod into eslint-plugin-testing-library #8

Belco90 opened this issue Jan 19, 2022 · 3 comments

Comments

@Belco90
Copy link

Belco90 commented Jan 19, 2022

Hi @atsikov!

This codemod repo is pretty useful! Would you be interested into bringing this into eslint-plugin-testing-library itself to corresponding rules as autofixes or suggestions?

@atsikov
Copy link
Owner

atsikov commented Jan 19, 2022

Hi @Belco90

I like the idea, however I'm not sure all the logic could be migrated to the plugin. As far as I know, unlike jscodeshift, eslint doesn't allow to parse module multiple times in a single rule, and at least prefer-screen-queries heavily relies on this feature.

I need to take a look which fixes are missing in your plugin and what could be migrated.

@Belco90
Copy link
Author

Belco90 commented Jan 20, 2022

That's a good point.

All the fixes from your codemod are missing in the plugin, so whatever could be migrated there would be really helpful.

@MincoKe
Copy link

MincoKe commented Dec 25, 2023

as I known, some code like import xxx from 'xxx.json' assert { type: 'json' }; will fail to transform
so I think it's a lot of effort to to this job

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

3 participants