Code Monkey home page Code Monkey logo

react-native-ios-charts's Introduction

react-native-ios-charts

NOT MAINTAINED, LOOKING FOR NEW PROJECT OWNER

It's been a while since I've been able to spend some time on this repo and I prefer to transfer it to someone that can do a better job at maintaining it than I am doing right now. If you are interested, please let me know right away at [email protected]

Take a look at react-native-charts-wrapper it's a library inspired by this one and by react-native-mp-android-chart.

npm version npm downloads

Bringing iOS Charts to React Native.

Image of all charts

Check out the ChartsExplorer in the examples folder

Introduction

The aim of this library is to provide reusable React Native components that can graph charts like Bar, Line, Scatter, Combined, Pie, Candle, Bubble from the awesome ios-charts library.

Installation

The minimum deployment target should be set to iOS 8.0 or greater

  1. Run npm install --save react-native-ios-charts
  2. Add all the files under node_modules/react-native-ios-charts/RNiOSCharts. (In Xcode: File -> Add files to "App Name")
  3. When you add the files XCode should prompt you to create a bridging header if you haven't done so already. Create it and import the RCTViewManager.h. It should look something like this.
#import "RCTBridge.h"
#import "RCTViewManager.h"
#import "RCTUIManager.h"
#import "UIView+React.h"

3.5. You can use CocoaPods and skip steps 4-6. Just add a Podfile to your ios directory with the following content. Then run pod install and open the generated .xcworkspace from now on in xcode.

use_frameworks!

target 'MyApp' do
  pod 'SwiftyJSON', git: 'https://github.com/IBM-Swift/SwiftyJSON.git'
  pod 'Charts', git: 'https://github.com/danielgindi/Charts.git'
end

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['SWIFT_VERSION'] = '3.0'
    end
  end
end
  1. Install SwiftyJSON and iOS Charts libraries and add SwiftyJSON.xcodeproj and Charts.xcodeproj files to your project.
  2. Under Build Phases, under Link Binary With Libraries, click the plus sign and add SwiftyJSON.framework and Charts.framework.
  3. Add the SwiftyJSON.framework and Charts.framework to the Embedded Binaries section in your app.
  4. In your project's build settings, go to build options and change the Embedded Content Contains Swift Code to Yes.

Usage

Currently supported charts:

Example code:

var { BarChart } = require('react-native-ios-charts');

var MyComponent = React.createClass({
  render: function() {
    return (
      <View style={styles.container}>
        <BarChart
          config={{
            dataSets: [{
              values: [1, 2, 3, 10],
              colors: ['green'],
              label: '2015',
            }, {
              values: [3, 2, 1, 5],
              colors: ['red'],
              label: '2014',
            }],
            labels: ['a', 'b', 'c', 'd'],
          }}
          style={styles.chart}
        />
      </View>
    );
  }
});

var styles = StyleSheet.create({
  chart: {
    width: 200,
    height: 200
  }
})

Roadmap

  • Support for all charts
  • Examples
  • Support for all chart properties
  • Documentation

License

The MIT License (MIT)

Copyright (c) 2016 Jose E. Padilla

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

react-native-ios-charts's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

react-native-ios-charts's Issues

Add LICENSE

Great work on this so far! Would like to start from your base and add some things (support for animations etc) but to do so it would be good to have a license sorted. MIT is my goto unless you have other thoughts?

Value of optional type 'RCTBridge?' not unwrapped; did you mean to use '!' or '?'?

Hi there.

I'm getting this error in the following files using react-native 0.28 and react-native-iso-charts 0.2.5:

node_modules/react-native-ios-charts/RNiOSCharts/RNBarChartManager.swift
node_modules/react-native-ios-charts/RNiOSCharts/RNScatterChartManager.swift
node_modules/react-native-ios-charts/RNiOSCharts/RNCandleChartManager.swift
node_modules/react-native-ios-charts/RNiOSCharts/RNLineChartManager.swift

I get past it by allowing Xcode to "fix it" which does adds a force unwrap. Problem is all of our developers have to do this the first time they build the app. Perhaps the module can be updated?

Installation Docs

Hi Jose,

Great work with this library. This is a request to improve the installation steps posted, most of them are very abstract and not easy to follow. I get to the end but there are two errors:

  1. CocoaPods
    image
  2. Xcode:

image

I already did the following:

  1. All the files on the RNiOSCharts directory I copied them to the ios folder.
  2. The bridging header file is created
  3. When I run pod install i got the error on (1)
  4. I already changed Embedded content contains swift to Yes.

After this I still get on Chrome debugger:

image

Cheers

Issue on RN 26

I had to use codemod to update components/ and utils/ to the latest syntax, removing the errors.

import React, { Component } from 'react';
import { Text, StyleSheet, View } from 'react-native';
import { BarChart } from 'react-native-ios-charts';

export default class ChartsView extends Component {
  constructor(props) {
    super(props);
  }
  render(){
    return (
      <View style={styles.container}>
        <Text>Hello</Text>
        <BarChart
          config={{
            dataSets: [{
              values: [1, 2, 3, 10],
              colors: ['green'],
              label: '2015',
            }, {
              values: [3, 2, 1, 5],
              colors: ['red'],
              label: '2014',
            }],
            labels: ['a', 'b', 'c', 'd'],
          }}
          style={styles.chart}
        />
      </View>
    );
  }
}

const styles = StyleSheet.create({
  container: {
    // borderWidth: 0,
    // borderColor: 'red',
    flex: 1,
    marginTop: 60,//cssConfig.header.height,
    justifyContent: 'flex-start',
    alignItems: 'center',
    // padding:0,
    backgroundColor: '#fafafa',
  },
  chart: {
    width: 200,
    height: 200
  }
});

screenshot 2016-05-26 10 18 01

And in the console I get a lot of errors, I think I missed something in the Xcode part, it didn't ask me to create a bridge when adding the files.

Instead I get:

screenshot 2016-05-26 10 18 22

Any ideas ?

Where do I add the chart files to?

Hi,

Hate to be a bother, but it isn't exactly clear where I add the chart files to in step 2. When I just add them straight under the Project directory (presumably in the xCode project under the ios folder), it doesn't prompt me to bridge the files at all.

Also, in step 3, which file do we import the RCTViewManager.h to?

Strange behavior in RN 0.26

I update the new version of charts and after that the result is:
screenshot 2016-06-10 10 42 30
I cannot change background color of chart and seem other config is not working too. My code for chart is
<LineChart config={{ dataSets: dataSet, labels: label, backgroundColor: 'white', minOffset: 20, scaleYEnabled: false, legend: { textSize: 12 }, xAxis: { axisLineWidth: 0, drawLabels: false, position: 'bottom', drawGridLines: false }, leftAxis: { customAxisMax: 1, customAxisMin: -1, labelCount: 11, startAtZero: false }, rightAxis: { enabled: false, drawGridLines: false }, valueFormatter: { minimumSignificantDigits: 1, type: 'regular', maximumDecimalPlaces: 1 } }} style={styles.chart} />

and when i click to chart it show duplicate line like that:

screenshot 2016-06-10 10 42 46
:( Any ideas about this issue.

viewportoffset is missing

By using chart.setViewPortOffsets() can make a chart full fill the space as mentioned in this thread. But it seems there is not way to do it in react-native-ios-charts.

ChartMarker not working?

Hi, I've added drawMarkers: true to my chart view
but it seems like ChartMarker not working?

render() {
    const config = {
      dataSets: [{
        values: [1000, 1100, 1205],
        colors: ['#45af28', '#45af28', '#45af28' ],
        highlightEnabled: true,
        drawValues: false,
        drawDescription: true,
        drawMarkers: true,
      }],
......

how should I fix it?

Installing ios chart component

Hi, I'm relatively new to React Native and Xcode. I'm trying to integrate the chart lib to my project. Following through the direction, can you please clarify on how I would Add all the files under node_modules/react-native-ios-charts/RNiOSCharts. ? Thanks.

A question about CombinedChart

I want to CombinedChart to combine BarChart and CandleStickChart, they have different meaning. BarChart may mean how many people, and CandleStickChart means price. Which mean they have different unit. Because BarChart value is very big[1000 - 10000], and CandleStick value is small[20 - 30]. How can i draw then in the same area?

Thanks.

get property defined in objC side

hey, it's not a issue and I just want to know how to get defined property in objC header file, could you provide some suggestion :)

for example, if I have below code, how could I access property config in foo.swift?

thanks for your time.

foo.h

#import "RCTView.h"


@interface Foo : RCTView

@property (nonatomic, assign) NSString *config;

@end

foo.m

#import "foo.h"
#import "RCTViewManager.h"
#import "RCTBridgeModule.h"


@interface RCT_EXTERN_MODULE(Foo, RCTViewManager)

RCT_EXPORT_VIEW_PROPERTY(config, NSString);

@end

foo.swift

import Foundation

@objc(Foo)
class Foo :  {

  func setConfig(config: String!) {
    // I just do set here, but I want to get config property.
  }

}

Chart Zooms when clicked

At the moment when I click on the chart in the iOS simulator, the chart can zoom in infinitely.

Is there a way to disable interaction with the chart. Or disable zooming specifically.

Is setLabelCount option supported?

Hi,
I was looking for the different supported options, which led me to the Charts library page, which refers to he MPAndroidChart library page.

I saw there that there's an option to limit the number of labels shown on the y axis (setLabelCount).
Can this be achieved in react-native-ios-charts?
If not, i'd be happy to try to add that option (would probably need a bit of help with kickstarting though...)

Thanks!
Uri

axisMaximum and axisMinimum have not effect

The config data looks like:

return {
    barData: {
      dataSets: [{
        values: barDataValue,
        drawValues: false,
        colors: ['rgb(211,211,211)']
      }]
    },
    candleData: {
      dataSets: [{
        values: candleDataValue,
        colors: candleDataColor,
        drawValues: false
      }],
    },
    drawBarShadowEnabled: false,
    backgroundColor: 'transparent',
    labels: labels,
    showLegend: false,
    drawBorders: true,
    xAxis: {
      position: 'bottom',
      avoidFirstLastClipping: true,
      textSize: 7.5,
      gridDashedLine: {
        lineLength: 1,
        spaceLength: 1
      }
    },
    leftAxis: {
      drawLabels: false,
      drawGridLines: false,
      spaceBottom: 0,
    },
    rightAxis: {
      drawGridLines: true,
      spaceBottom: 0,
      gridDashedLine: {
        lineLength: 1,
        spaceLength: 1
      },
      axisMaximum: 1000,
      axisMinimum: 100
    },
    valueFormatter: {
      type: 'regular',
      maximumDecimalPlaces: 0
    }
  };

But the chart looks like
screen shot 2016-04-07 at 10 54 14 pm

As you can see, the max value and min value is not 1000 and 100.

strange PercentStyle of valueFormatter

I use pie chart and set some custom config.

usePercentValuesEnabled: true,
valueFormatter: {
  numberStyle: 'PercentStyle',
},

but display a bit strange like below image

image

when I change numberStyle: 'DecimalStyle',, it display correctly but without percentStyle :(

image

how could I fix it?

thanks for your time.

XCode 8 + Swift 2.3 / Swift 3 issues

Hi,
As I installed XCode 8 it asked me if I want to convert the files to the latest Swift version.
Regardless of what I say (Later / Convert) I get tons of exceptions from XCode (even XCode 7 doesn't work now, tried installing that one too). The exceptions look like this:
screen shot 2016-09-21 at 1 17 16
Of course there are many more exceptions under these (200+ / 600+ depending on if I chose to upgrade or not)
Does anyone have a solution for this if I just wanna use the old version from everything?

Thanks!

Swift 2.3 and 3.0 support ?

Hi there,

I updated my Xcode version to 8.0 and it asks me for a Swift conversion to 2.3 or 3.0.
I have therefore updated the Charts and SwiftyJSON pods to use the 2.3 version of Swift but still have errors such as " Type 'CombinedChartView.DrawOrder' has no member 'bar'" in RNCombinedChart.swift and all other swift files in node_modules/react-native-ios-charts.

Not knowing Swift, I haven't been able to fix the errors in order to create a PR on your repo. Can you help me ? Are you maybe currently working on the conversion to support Swift's latest version ?
I would love to help.
Thanks for your answer

Error node-gyp with [email protected]

Hello,

I am getting the following error with RN 0.20. I know this is not an error with your component but with a dependency. I looked online for solutions but couldn't find any that worked. Have you encountered this issue before? Do you know what could be causing it?

Thanks so much

$ npm install --save react-native-ios-charts

> [email protected] install /Users/user/Hive/Hive/node_modules/bufferutil
> node-gyp rebuild

  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/bufferutil.node
ld: library not found for -lgcc_s.10.5
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Release/bufferutil.node] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270:23)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:172:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 15.2.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/user/Hive/Hive/node_modules/bufferutil
gyp ERR! node -v v5.3.0
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok 
npm WARN install:[email protected] [email protected] install: `node-gyp rebuild`
npm WARN install:[email protected] Exit status 1
[email protected] /Users/user/Hive/Hive
└── [email protected] 

Call for maintainers

As you all may have noticed, I haven't been as active in this repo as before and I'm sorry. This issue has the sole purpose of calling maintainers that are willing to keep this repo alive better than I'm doing right now. If anyone is interested please let me know.

No Swift-3.0 Branch

Hi there.

I was trying to install this module according to your readme and got the following error:

Pre-downloading: `Charts` from `https://github.com/danielgindi/Charts.git`, branch `Swift-3.0`

[!] Error installing Charts
[!] /usr/bin/git clone https://github.com/danielgindi/Charts.git /var/folders/nz/__btsnk12tbbqlmk1_gkr0kc0000gn/T/d20160921-14615-uc3mfs --template= --single-branch --depth 1 --branch Swift-3.0

Cloning into '/var/folders/nz/__btsnk12tbbqlmk1_gkr0kc0000gn/T/d20160921-14615-uc3mfs'...
warning: Could not find remote branch Swift-3.0 to clone.
fatal: Remote branch Swift-3.0 not found in upstream origin

I've tried replacing that line with one of the other branches found in the Chards repo but I get various errors no matter what I choose. Any chance you can verify this podfile entry?

Cropped labels when font size is too big

Hi there.
Great component here, good job !

I am trying to add labels at the bottom of my charts.
The labels are dates and are quite long and I see the first label cropped (see screenshot)

screen shot 2016-07-15 at 14 06 30

The only solution I found was to reduce the font size but my specs require a larger font.
Is there anyway to deal with this overflow issue ?

Thank you very much in advance

build failed

following the Installation Instruction, and then run react-native run-ios and I got the following errors. thanks

/Users/xx/Projects/demo/node_modules/react-native-ios-charts/RNiOSCharts/PieRadarChartViewBaseExtension.swift:22:12: error: value of type 'JSON' has no member 'isExists'
if json["rotationEnabled"].isExists() {
~~~~^~~~~~~~~~~~~~~~~~~ ~~~~~~~~
/Users/xx/Projects/demo/node_modules/react-native-ios-charts/RNiOSCharts/PieRadarChartViewBaseExtension.swift:26:12: error: value of type 'JSON' has no member 'isExists'
if json["rotationAngle"].isExists() {
~~~~^~~~~~~~~~~~~~~~~ ~~~~~~~~
/Users/xx/Projects/demo/node_modules/react-native-ios-charts/RNiOSCharts/PieRadarChartViewBaseExtension.swift:30:12: error: value of type 'JSON' has no member 'isExists'
if json["rotationWithTwoFingers"].isExists() {
~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~
/Users/xx/Projects/demo/node_modules/react-native-ios-charts/RNiOSCharts/PieRadarChartViewBaseExtension.swift:34:12: error: value of type 'JSON' has no member 'isExists'
if json["minOffset"].isExists() {
~~~~^~~~~~~~~~~~~ ~~~~~~~~

Is "labels" attribute required for LineChart?

This is really helpful for my project.
It seems like the "labels" attribute is not a requirement for LineChart, but if you omit this attribute, the chart will only draw the first two values of the "values" array, which is weird.
Is this a bug? or is there some other way to omit the "labels" and just draw line chart of the "values"?
I'm letting the "labels" be values.length sized array of empty strings for now, but this seems too hacky.
Thanks!

setting config 'colors' broken

Hey there, I've been attempting to set the colors on both a line chart and pie chart but both crash the app.
I attempted this on react-native 0.21, but I've now discovered colorProcessing was reimplemented in 0.21 and no longer supports arrays of colors (facebook/react-native@c8a0a3e)

Though I rolled back to both 0.20 and 0.19 and both give same error, I'm unsure if this is something of my own doing or a issue with this library. I tried using the sample code from the readme and produced the same results, regardless here is my render code to produce the error.

<View style={styles.container}>
        <View style={{ marginTop: 50, flexDirection: 'row'}}>
          <LineChart
            config={{
              dataSets: [{
                values: [1, 2, 3, 10, 3, 2, 1, 5, 13, 10, 11, 14, 2, 5, 1, 5, 12, 19, 12],
                colors: ['red'],
                drawValues: false,
                drawFilled: true,
                circleRadius: 3,
                drawHorizontalHighlightIndicator: false,
                drawVerticalHighlightIndicator: false,
              }],
              labels: ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n'],
              showLegend: false,
              xAxis: {enabled: false},
              leftAxis: { enabled: false},
              rightAxis: { enabled: false},
              animation: {  xAxisDuration: 1,
                            yAxisDuration: 1,
                            easingOption: 'easeOutExpo'},
              scaleYEnabled: false,
            }}
            style={styles.chart}
          />
        </View>
 </View>

Here's where it crashes in RNLineChart.swift

screen shot 2016-03-04 at 3 42 57 pm

Build Error - No such module 'Charts'

Hi @Jpadilla1,
I'm trying to install the library (v0.2.6). I'm running react-native v0.32.0. I've followed the installation instructions one by one, and when I try to run the project via the .xcworkspace file in Xcode, i'm getting the error:
No such module 'Charts'
In the file: RNBubblrChart.swift

I installed Charts and SwiftyJSON using Cocoapods

Any idea what the issue is? I'd be happy to provide any additional information needed.
Thanks!
Uri

array cannot be bridged from Objective-C

when I call setState() or render() method, below error appear.

fatal error: array cannot be bridged from Objective-C

error

by the way, it's the awesome project which I need :)

Build Failed

Hello,

I am getting the following error when trying to build on React Native 0.19:

** BUILD FAILED **

The following build commands failed:
    CompileSwift normal x86_64 /Users/[USER]/Project/ReactProject/node_modules/react-native-ios-charts/RNiOSCharts/Libraries/Charts/Classes/Charts/BubbleChartView.swift
    CompileSwift normal x86_64 /Users/[USER]/Project/ReactProject/node_modules/react-native-ios-charts/RNiOSCharts/Libraries/Charts/Classes/Charts/LineChartView.swift
    CompileSwift normal x86_64 /Users/[USER]/Project/ReactProject/node_modules/react-native-ios-charts/RNiOSCharts/Libraries/Charts/Classes/Components/ChartYAxis.swift
    CompileSwift normal x86_64 /Users/[USER]/Project/ReactProject/node_modules/react-native-ios-charts/RNiOSCharts/Libraries/SwiftyJSON/Tests/SequenceTypeTests.swift
    CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler
(5 failures)
Installing build/Build/Products/Debug-iphonesimulator/ReactProject.app
An error was encountered processing the command (domain=LaunchServicesError, code=0):
The operation couldn’t be completed. (LaunchServicesError error 0.)
Launching $(PRODUCT_BUNDLE_IDENTIFIER)

An error was encountered processing the command (domain=FBSOpenApplicationErrorDomain, code=4):
The operation couldn’t be completed. (FBSOpenApplicationErrorDomain error 4.)

Do you know what could be causing the issue ?

Thanks so much

Support for CandleStick Chart

In my current project I've requirement to use CandleStick chart in react native. I looked into your other charts implementation and tried working on CandleStick Chart support myself. But, my lack of iOS knowledge led to failure. Do you have any plans to add support for this chart anytime soon? If not, I'm open to take this on me and try again if I could get some guidance.

red square and no chart appearing

hi, i've done all the installation instructions but nothing appears, only a red square around the zone where the chart is supposed to be, any idea of what the problem can be ?
thx :)

Library not found for -lRNChart

Has anyone else stumbled upon the following issue? I get this when I try to test against actual physical device. Virtual simulator seems to work fine.
ld: library not found for -lRNChart clang: error: linker command failed with exit code 1 (use -v to see invocation)

Missing customAxisMin and customAxisMax members in ChartAxisBase.swift

Hi,

I've just installed the react-native-ios-charts based on your instruction but I've encoutered the following iOS compiling errors in the BarLineChartViewBaseExtension.swift:

if json["leftAxis"]["axisMinimum"].isExists() { self.leftAxis.customAxisMin = json["leftAxis"]["axisMinimum"].doubleValue; }

if json["leftAxis"]["axisMaximum"].isExists() { self.leftAxis.customAxisMax = json["leftAxis"]["axisMaximum"].doubleValue; }

The errors are:

"Value of type 'ChartYAxis' has no member 'customAxisMin'

and

"Value of type 'ChartYAxis' has no member 'customAxisMax'

Searching through the pods and I found that in CharAxisBase.swift that there are only these two declarations:

/// Flag indicating that the axis-min value has been customized internal var _customAxisMin: Bool = false
/// Flag indicating that the axis-max value has been customized internal var _customAxisMax: Bool = false

It seems that that the customAxisMin and customAxisMax are not declared as public members in your Pods files, not in the ChartAxisBase.swift or the ChartYAxis.swift.

Here is my podfile entries:

pod 'SwiftyJSON', '> 2.3'
pod 'Charts', '
> 2.2'

Are you missing some updates to the CocoaPods or am I doing something wrong?

I'm pretty much stuck here and need some helps.

has no member customAxisMin and customAxisMax

list native chart and react native side version

react-native-ios-charts: 0.2.4
danielgindi/Charts: 2.2.4

I found some problem when I execute build.

error

how should I fix it?

thanks for your time :)

Gradient fill

Does the LineChart component support gradient fill color via config? Thanks.

could I custom callback to this smart chart?

hi, thanks for your smart chart in react-native js side, it's cool and convenient.

I want to get x axis and y axis value when I interact with chart component, I notice that native Android implements almost all event type while iOS also implement part of some,

but I can't find any bridge which defined in our component swift code, maybe I'm missing, how could I custom callback here?

thanks for your time.

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.