npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@baykan/react-native-linechart-native

v1.7.5

Published

A performant Line Chart for React Native using Fabric

Downloads

232

Readme

React Native Line Chart

🚀 Features

⚡ Performance-Oriented(Fast Line Chart for React Native)

  • High-speed rendering: Charts are rendered natively with immediate response.
  • High FPS animations: Smooth animations running at 60 FPS and above.
  • Low CPU/GPU usage: Rendering is offloaded to native modules optimized for performance.
  • Compatible with React Native Fabric: Uses the new architecture for low-latency communication between JS and native layers.
  • Fully native chart code: All chart logic and rendering are compiled natively (Android/iOS), not JavaScript.

🟡 User Experience & Interaction(React Native Chart Component)

  • 🟡 Smooth gesture support: Fast, fluid interactions like pan and tap with no lag.
  • 🟡 Seamless transition effects: Animated transitions deliver a polished, professional feel.
  • 🟡 Modern API design: Simple and flexible for developers to use.
  • 🟡 Scalable performance: Handles large datasets without stuttering.

Requirements Only react-native supports the new architecture

Install Below is the command to install the package

yarn add @baykan/react-native-linechart-native

Only for Ios:

 pod install

Example Screenshots

| iOS Example | Android Example | | -------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ | | | |

Example Usage

import { SafeAreaView, StyleSheet, View } from 'react-native';
import { LineChartNativeComponent } from '@baykan/react-native-linechart-native';

function App(): JSX.Element {
  const count = 25;
  const range = 60;

  const values = Array.from({ length: count }, (_, i) => {
    const val = Math.floor(Math.random() * range) + 3;
    return { x: i, y: val };
  });

  const lineData = {
    dataSets: [
      {
        values: values,
        drawVerticalHighlightIndicatorEnabled: true,
        drawValuesEnabled: false,
        mode: 'linear',
        drawHorizontalHighlightIndicatorEnabled: false,
        gradientColorsData: { from: '#ffffff', to: '#080707' },
        label: 'Chart1',
        limitLineEntity: {
          lineWidth: 3.0,
          lineColor: '#d6371e',
          lineDashLengths: [5, 2],
          labelPosition: 'leftTop',
          labelValueColor: '#d6371e',
          fontSize: 15,
          limit: 12,
        },
      },
    ],
  };

  return (
    <SafeAreaView style={styles.container}>
      <View
        style={{
          flex: 1,
          height: 550,
          justifyContent: 'center',
          alignItems: 'center',
        }}
      >
        <LineChartNativeComponent
          data={lineData}
          markerEntity={{
            color: '#161617',
            fontSize: 17,
            bgColor: '#ffffff',
            circleEntity: { size: 13, color: '#1e498f' },
            position: { left: 8, top: 0, bottom: 0, right: 8 },
          }}
          xAxisEntity={{
            drawLabelsEnabled: true,
            labelPosition: 'bottom',
            labelFont: { size: 15, weight: 'bold' },
            labelTextColor: '#080707',
            yOffset: 10,
            xOffset: 0,
          }}
          yAxisEntity={{
            drawLabelsEnabled: true,
            labelPosition: 'outside',
            labelFont: { size: 15, weight: 'bold' },
            labelTextColor: '#080707',
            xOffset: 0,
            yOffset: 0,
            axisMin: 0,
            axisMax: 120,
          }}
          animationEntity={{
            xAxisDuration: 0.8,
            xAxisEasing: 'linear',
            yAxisDuration: 1,
            yAxisEasing: 'linear',
          }}
          highlightPerDragEnabled={true}
          highlightPerTapEnabled={true}
          drawGridLinesEnabled={true}
          dragEnabled={true}
          style={{ width: '100%', height: 500, margin: 16 }}
        />
      </View>
    </SafeAreaView>
  );
}

const styles = StyleSheet.create({
  container: {
    flex: 1,
    backgroundColor: '#f4f6f8',
  },
});
export default App;

Props

| Property | Type | Description | | ------------------------- | ----------------- | ------------------------------------------------------------------------------------------ | | data | LineData | The name of the props variable that will show the data of the chart. | | dragEnabled | boolean | Activates/passivates the movement of the highlights gradient of a chart's background. | | bgColor | string | Defines the background color of the chart. use hex code ! | | animationEntity | AnimationEntity | Provides effective loading of the chart with animation. | | drawGridLinesEnabled | boolean | Provides visibility of lines on the x-axis of the chart. | | markerEntity | MarkerEntity | Shows the y-point values of the chart moving above the highlighter. | | xAxisEntity | XAxisEntity | Defines x-axis label properties and formatting. | | yAxisEntity | YAxisEntity | Defines y-axis label properties and formatting. | | highlightPerTapEnabled | boolean | If set to true, when the user touches a data point, it will be highlighted. | | highlightPerDragEnabled | boolean | Allows dragging to highlight data points. | | circleEntity | CircleEntity | Together with the highlighter, it makes the round circle appear. | | dataSets | object[] | Each index in dataSets represents a line, which can be customized with these properties. | | limitLineEntity | object | Defines limit line properties, including width, color, and label settings. |

Type Definitions

AnimationEntity

{
  xAxisDuration: number;
  yAxisDuration: number;
  xAxisEasing: string;
  yAxisEasing: string;
}

MarkerEntity

{
  bgColor: string;
  color: string;( use hex code string type)
  fontSize: number;
  position: {
    left: number;
    top: number;
    bottom: number;
    right: number;
  };
  circleEntity?: CircleEntity;
}

XAxisEntity

{
  drawLabelsEnabled: boolean;
  labelPosition: string;
  labelFont?: LabelFont;
  labelTextColor?: string;
  yOffset?: number;
  xOffset?: number;
  axisMin?: number;
  axisMax?: number;
}

YAxisEntity

{
  drawLabelsEnabled: boolean;
  labelPosition: string;
  labelFont?: LabelFont;
  labelTextColor?: string;( use hex code)
  xOffset?: number;
  yOffset?: number;
  axisMin?: number;
  axisMax?: number;
}

CircleEntity

{
  size: number;
  color: string;( use hex code)
}

dataSets

{
  values: DataSetEntry[];
  limitLineEntity: LimitLineEntity;
  label: string;
  gradientColorsData: { from: string; to: string };
  drawVerticalHighlightIndicatorEnabled: boolean;
  drawHorizontalHighlightIndicatorEnabled: boolean;
  drawValuesEnabled: boolean;
  mode: Mode;
}

LimitLineEntity

{
  lineWidth: number;
  lineColor: string;
  lineDashLengths: number[];
  labelPosition: string;
  fontSize: number;
  limit?: number;
  label?: string;
  labelValueColor?: string;
}

Line Chart Type (Mode prop)

mode: 'cubicBezier' | 'stepped' | 'linear' | 'horizontalBezier';

Line Chart Type xAxisEasing,yAxisEasing

ChartEasingOptionProps: {
  Linear = 'linear',
  EaseInQuad = 'easeInQuad',
  EaseOutQuad = 'easeOutQuad',
  EaseInOutQuad = 'easeInOutQuad',
  EaseInCubic = 'easeInCubic',
  EaseOutCubic = 'easeOutCubic',
  EaseInOutCubic = 'easeInOutCubic',
  EaseInQuart = 'easeInQuart',
  EaseOutQuart = 'easeOutQuart',
  EaseInOutQuart = 'easeInOutQuart',
  EaseInQuint = 'easeInQuint',
  EaseOutQuint = 'easeOutQuint',
  EaseInOutQuint = 'easeInOutQuint',
  EaseInSine = 'easeInSine',
  EaseOutSine = 'easeOutSine',
  EaseInOutSine = 'easeInOutSine',
  EaseInExpo = 'easeInExpo',
  EaseOutExpo = 'easeOutExpo',
  EaseInOutExpo = 'easeInOutExpo',
  EaseInCirc = 'easeInCirc',
  EaseOutCirc = 'easeOutCirc',
  EaseInOutCirc = 'easeInOutCirc',
  EaseInElastic = 'easeInElastic',
  EaseOutElastic = 'easeOutElastic',
  EaseInOutElastic = 'easeInOutElastic',
  EaseInBack = 'easeInBack',
  EaseOutBack = 'easeOutBack',
  EaseInOutBack = 'easeInOutBack',
  EaseInBounce = 'easeInBounce',
  EaseOutBounce = 'easeOutBounce',
  EaseInOutBounce = 'easeInOutBounce',
}

CoupleLineChart