Giter Site home page Giter Site logo

Comments (15)

MohammadFakhreddin avatar MohammadFakhreddin commented on May 2, 2024 10

When you already have react-native-svg as a dependency this error happens,As work around ,I removed react-native-svg from chart-kit node module folder.
Please fix this issue

from react-native-chart-kit.

ffigueroa avatar ffigueroa commented on May 2, 2024 4

I have the same issue because this library uses Expo, when I create a project using Expo the react-native-svg tries to register RNSVGPath again.

npm list react-native-svg
├─┬ [email protected]
│ └── [email protected]
└─┬ [email protected]
└─┬ [email protected]
└── [email protected]

from react-native-chart-kit.

jdpagley avatar jdpagley commented on May 2, 2024 4

Why has this issue been closed? It's still a problem in the current version of this module?

from react-native-chart-kit.

csumrell avatar csumrell commented on May 2, 2024 1

Tried to install and test this package, getting the same errors

from react-native-chart-kit.

gagso avatar gagso commented on May 2, 2024

I am facing the same problem. Anyways to fix this ?

from react-native-chart-kit.

Hermanya avatar Hermanya commented on May 2, 2024

Sorry for the late response. I just updated all dependencies for this library.
You can also checkout a working example.

from react-native-chart-kit.

kaiszybiak avatar kaiszybiak commented on May 2, 2024

Still have the same issue.

from react-native-chart-kit.

lwansbrough avatar lwansbrough commented on May 2, 2024

Perhaps this library can use "react-native-svg": "*" as its peer dependency. That would leave version compatibility ambiguous but allows different versions. I'm on react-native-svg 8.0.3, but I'd bet the API hasn't changed to the point of being incompatible with 6.4.1.

from react-native-chart-kit.

DanishDeveloper360 avatar DanishDeveloper360 commented on May 2, 2024

I have the same issue because this library uses Expo, when I create a project using Expo the react-native-svg tries to register RNSVGPath again.

npm list react-native-svg
├─┬ [email protected]
│ └── [email protected]
└─┬ [email protected]
└─┬ [email protected]
└── [email protected]

Any resolution yet?

from react-native-chart-kit.

tolulope-od avatar tolulope-od commented on May 2, 2024

I have the same issue because this library uses Expo, when I create a project using Expo the react-native-svg tries to register RNSVGPath again.

npm list react-native-svg
├─┬ [email protected]
│ └── [email protected]
└─┬ [email protected]
└─┬ [email protected]
└── [email protected]

Any solution to this yet? I am trying to use victory-native on expo and I am running into this issue

from react-native-chart-kit.

OmniAsetty avatar OmniAsetty commented on May 2, 2024

Today I upgraded my app to use Expo v32, I started facing same issue. Any solution for this problem?

from react-native-chart-kit.

DanishDeveloper360 avatar DanishDeveloper360 commented on May 2, 2024

@OmniAsetty I resolved this issue with below

import React from "react";
import { View } from "react-native";
import { LineChart, YAxis, Grid } from "react-native-svg-charts";
import "react-native-svg";
import { Button } from "react-native-elements";
import Icon from "react-native-vector-icons/FontAwesome";

https://github.com/DanishDeveloper360/climate-control-app-hr/blob/master/screens/SettingsScreen.js

Feel free to look into my code, but I resolved it with this line :
import "react-native-svg";

Also, this error sometimes comes when you access your uninitialised state, I know it is stupid but I happened don;t for what reason.

from react-native-chart-kit.

OmniAsetty avatar OmniAsetty commented on May 2, 2024

Thank you for prompt response! I will give a try and let you know.

from react-native-chart-kit.

OmniAsetty avatar OmniAsetty commented on May 2, 2024

Is package 'react-native-chart-kit' and 'react-native-svg-charts' are same?
In 'react-native-chart-kit', LineChart component accepts the data in this format
const data = { labels: [], datasets: [{ data: [] }] };
but react-native-svg-charts, LineChart component accepts the data as [].

from react-native-chart-kit.

OmniAsetty avatar OmniAsetty commented on May 2, 2024

I got it resolved! I am not 100% sure about this solution for every case, but in my case, my Expo cache and NPM cache was messed up. I had to delete the node_modules folder, do npm install and start the Expo with '-c' to clear the cache before it start. After this, it worked like a champ!

from react-native-chart-kit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.