-
-
Notifications
You must be signed in to change notification settings - Fork 428
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
React-Native with TypeScript breaks on typecheck #465 #488
Conversation
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/gregberge/svgr/468u6w8fe |
By looking into Travis output and reducing the test down to |
@Ztarbox thanks, could you please remove the change in the |
I reset my changes of |
👋 @gregberge , When you can merge this PR, please? Any expectation! |
Summary
To fix #465 I updated the type annotations for react-native.
I also found to support the eslint rule @typescript-eslint/explicit-function-return-type we would need to add the return type if the typescript flag is present. But I have no idea how to implement that.
Test plan
I didn't get it with jest. It gave me (w/o changes) so much errors and deprecated snapshots. I lost sight.
Also I tried to just add to cli/src/index.test.js to 'should support various args', but jest didn't run it.
So I did manual tests:
svgr --native --typescript ../../../__fixtures__/simple/file.svg --silent
node svgr --native ../../../__fixtures__/simple/file.svg --silent
node svgr --native --typescript --ref ../../../__fixtures__/simple/file.svg --silent