Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Instruction for clearing cache does not work with react-native 0.57 #52

Open
mieszko4 opened this issue Jan 24, 2019 · 10 comments
Open

Comments

@mieszko4
Copy link

This instruction:

{
  "scripts": {
    "start": "rm -rf ./node_modules/.cache/babel-loader && node index.js"
  }
}

does not work with react-native 0.57

Is there any way to fix it in react-native?

@mieszko4
Copy link
Author

As a workaround I read and tried to write comment in file that imports the .graphql file to bust cache.
Also I believe this issue is related to evenchange4/graphql.macro#6

@iamnader
Copy link

I had to rename files. I couldn't get the cache busted

@Sceat
Copy link

Sceat commented Jun 14, 2019

doesn't work in basic node neither

@oxyii
Copy link

oxyii commented Jul 4, 2019

@mieszko4 @iamnader react-native start --reset-cache works for me

@iamnader
Copy link

Thanks @oxyii. For any Expo users expo start -c does the trick in Expo SDK >= 33

@Skitionek
Copy link

rm -rf ./node_modules/.cache/@babel
helps at least fo babel-node

@switz
Copy link

switz commented Jan 26, 2020

Thanks @oxyii. For any Expo users expo start -c does the trick in Expo SDK >= 33

Been fighting this one for a while, thank you.

@LP1994
Copy link

LP1994 commented Jun 13, 2020

When using dynamic import, modifying ". Graphql" will trigger recompilation! But static import will not!

SO!!!
Recommended:
import('gQLDir/GraphQLDemo.graphql');
OR
import('../../../graphQL/GraphQLDemo.graphql');

@LP1994
Copy link

LP1994 commented Jun 13, 2020

With the dynamic import I mentioned above, there is no need to use script commands to delete the cache.

@DomVinyard
Copy link

Dynamic import is not always an option, is there any other workaround?

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

9 participants