Skip to content
This repository has been archived by the owner on Sep 17, 2021. It is now read-only.

Errors when using RN 0.40 #66

Closed
Eyesonly88 opened this issue Jan 31, 2017 · 2 comments
Closed

Errors when using RN 0.40 #66

Eyesonly88 opened this issue Jan 31, 2017 · 2 comments

Comments

@Eyesonly88
Copy link

So I upgraded my project to RN 0.40 and pathjs charts doesn't seem to work anymore as seen below. I read in another issue that this library may not work with 0.40 just yet but wanted to make sure that's the case and that there is no workaround.

I'm using pathjs-chart 0.0.24 and RN 0.40 running on iOS.

Drawing a basic bar chart like this:

...
<Bar data={data} options={options} accessorKey='v' />
...

image

Cheers.

@marzolfb
Copy link
Contributor

You didn't mention which version of react-native-svg you are using but assuming you didn't explicitly upgrade to a newer version of react-native-svg and stayed at version 4.4.1 (which is what you get by default with a npm install), this is the error I receive as well.

I'm not totally sure what the reason for the error is but I will mention that the react-native-svg README indicates that versions 4.5.0 and greater are meant to work with react-native 0.40. It also says this:

react-native-svg >= 4.4.0 only supports react-native >= 0.38.0

I'm not sure if that is really meant to say this instead:

react-native-svg >= 4.4.0 only supports react-native >= 0.38.0 and < 0.40.0

Regardless, my comments on #58 show the behavior differences I experienced when I upgraded to react-native 0.40 and tried to use react-native-svg versions of both 4.6.1 and 5.14. I didn't get the error above with either of those versions and I did see charts rendered, I just didn't see them rendered correctly as I would expect and that is why I've held off upgrading this library to target react-native >= 0.40.0 just yet.

@marzolfb
Copy link
Contributor

marzolfb commented Feb 2, 2017

Summarizing my comments above, the targeting of an older react-native-svg version (4.4.1) is driving the need to stay on an older version of react-native (0.38.0). Until there is more stability in react-native-svg, this lib will continue to target older versions. Closing this for now and hoping for more stability in future versions of react-native-svg to allow newer react-native versions to be used.

@marzolfb marzolfb closed this as completed Feb 2, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants