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

ART to react-native-svg migration #5

Open
4 tasks
redpandatronicsuk opened this issue May 24, 2017 · 0 comments
Open
4 tasks

ART to react-native-svg migration #5

redpandatronicsuk opened this issue May 24, 2017 · 0 comments

Comments

@redpandatronicsuk
Copy link
Owner

redpandatronicsuk commented May 24, 2017

There were some issue with the ART library on Android, so I decided to use react-native-svg instead. Not sure if that was a good idea though. I have some general questions, if you know the answer or can otherwise contribute to the discussion, please post a comment.

  1. I read the RN ART implementation is more efficient than react-native-svg, but that some while ago and might have changed. This is the main reason why I decided to use ART rather than react-native-svg in the first place!
  2. ART is already shipped with RN, whilst react-native-svg needs to be installed with npm. For iOS, ART needs to be linked manually in XCode, whilst for react-native-svg you can just use react-native link, so the effort for installing each one is about the same. Is it possible to make the SVG installation automatic by adding a post-install script or something like that to package.json?
  3. Does react-native-svg support the standard Animatable from RN? For ART that didn't work and I ended up writing a custom Tweener class, which updates values on the state in requestAnimatinFrame loop.
  4. What about the name? ARTy Charty no longer makes sense, but SVGy Charty doesn't sound as good. Any suggestions?

TO-DO

  • react-native-svg supports tags, so repeating stuff, such as markers, etc., should be only defined once in and then refer to it with afterwards
  • react-native-svg supports other elements than just Path, so maybe we can remove our functions that make SVG paths from shape parameters. test which is more efficient, probably using the react-native-svg elements
  • Check if all features still work, especially things like strokeDasharray, if I remember correctly, the ART implementation of that feature used slightly different parameters than normal SVG
  • Clean up code - the SVG migration was rather rushed and dirty, needs clean up!!
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

1 participant