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

Codemods-scripts missing in 5.0.0-alpha.14 #5230

Closed
christianhultin opened this issue Apr 5, 2023 · 5 comments · Fixed by #5340
Closed

Codemods-scripts missing in 5.0.0-alpha.14 #5230

christianhultin opened this issue Apr 5, 2023 · 5 comments · Fixed by #5340
Labels
bug Something isn't working v5

Comments

@christianhultin
Copy link

christianhultin commented Apr 5, 2023

Describe the bug

Thanks for a great project! It looks like the latest alpha-release (5.0.0-alpha.14) are missing the codemod-scripts-folder

Your minimal, reproducible example

Steps to reproduce

  1. Get the latest alpha release (5.0.0-alpha.14)
  2. Run the following script
npx jscodeshift ./path/to/src/ \
  --extensions=ts,tsx \
  --parser=tsx \
  --transform=./node_modules/@tanstack/react-query/codemods/v5/remove-overloads/remove-overloads.js
  1. Recieve error that file is not found

Expected behavior

File is found :)

How often does this bug happen?

Every time

Screenshots or Videos

Platform

  • OS: Mac

Tanstack Query adapter

react-query

TanStack Query version

5.0.0-alpha.14

TypeScript version

v5.0.3

Additional context

@TkDodo
Copy link
Collaborator

TkDodo commented Apr 5, 2023

@balazsmatepetro can you have a look please? I think codemods are their own package in the monorepo now, but we wouldn't want them to be their own package on npm. Can we include the codemod files in the framework distributions (react/vue/solid/svelte) so that the command mentioned in the migration guide works ?

@TkDodo TkDodo added bug Something isn't working v5 labels Apr 5, 2023
@phamquocduy
Copy link

Just want to mention that the codemode was missing already in version 5.0.0-alpha.12 (available in npm)

@balazsmatepetro
Copy link
Contributor

I will take a look. Thank you for mentioning it! 🙏

@jasikpark
Copy link

I'm seeing this fail w/ 5.0.0-alpha.21, though I wasn't able to find the file in my node modules, so I can't blame pnpm like I intended to xD

@TkDodo
Copy link
Collaborator

TkDodo commented Apr 28, 2023

fixed with #5340

please note that the location of the codemods has slightly changed - I updated the migration guide

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working v5
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants