All Projects → postlight → React Google Sheet To Chart

postlight / React Google Sheet To Chart

📊 React component that renders Google Sheets as attractive charts with minimum effort

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to React Google Sheet To Chart

scalajs-highcharts
Scala.js static typed facades for Highcharts library
Stars: ✭ 30 (-33.33%)
Mutual labels:  charts, charting
Unity Ugui Xcharts
A charting and data visualization library for Unity. 一款基于UGUI的数据可视化图表插件。
Stars: ✭ 1,086 (+2313.33%)
Mutual labels:  charts, charting
Amcharts4
The most advanced amCharts charting library for JavaScript and TypeScript apps.
Stars: ✭ 907 (+1915.56%)
Mutual labels:  charts, charting
Anychart Android
AnyChart Android Chart is an amazing data visualization library for easily creating interactive charts in Android apps. It runs on API 19+ (Android 4.4) and features dozens of built-in chart types.
Stars: ✭ 1,762 (+3815.56%)
Mutual labels:  charts, charting
HCLineChartView
HCLineChartView is a beautiful iOS library for drawing line charts. It is highly customizable and easy to use.
Stars: ✭ 22 (-51.11%)
Mutual labels:  charts, charting
Lightweight Charts
Financial lightweight charts built with HTML5 canvas
Stars: ✭ 4,390 (+9655.56%)
Mutual labels:  charts, charting
Ggnet
GG.Net Data Visualization
Stars: ✭ 45 (+0%)
Mutual labels:  charts, charting
Nats K8s
Various k8s/nats artifacts in experimental work.
Stars: ✭ 12 (-73.33%)
Mutual labels:  charts
3d kibana charts vis
3D Kibana Charts: Pie Chart, Bars Chart, Bubbles Chart
Stars: ✭ 34 (-24.44%)
Mutual labels:  charts
Teechart Vcl Samples
Sample programs showing how to use TeeChart VCL for Delphi and C++ Builder
Stars: ✭ 24 (-46.67%)
Mutual labels:  charts
Reasonbizcharts
ReasonML binding for BizCharts https://bizcharts.net/products/bizCharts/demo
Stars: ✭ 23 (-48.89%)
Mutual labels:  charts
Eon
An open-source chart and map framework for realtime data.
Stars: ✭ 875 (+1844.44%)
Mutual labels:  charts
F2
📱📈An elegant, interactive and flexible charting library for mobile.
Stars: ✭ 7,619 (+16831.11%)
Mutual labels:  charts
Kchartview
KChart for Android ;股票k线图
Stars: ✭ 864 (+1820%)
Mutual labels:  charts
Kdchart
A Qt tool for creating business and scientific charts. This is the canonical repository for KDChart.
Stars: ✭ 42 (-6.67%)
Mutual labels:  charts
Helm Charts
Prometheus community Helm charts
Stars: ✭ 962 (+2037.78%)
Mutual labels:  charts
Notion Charts
API to build charts for your notion.so database
Stars: ✭ 45 (+0%)
Mutual labels:  charts
Resonance
◾️Resonance | 5kb React animation library
Stars: ✭ 1,011 (+2146.67%)
Mutual labels:  charts
Apps
Community App Catalog for TrueNAS SCALE
Stars: ✭ 32 (-28.89%)
Mutual labels:  charts
React Google Charts
A thin, typed, React wrapper over Google Charts Visualization and Charts API.
Stars: ✭ 944 (+1997.78%)
Mutual labels:  charts

React Google Sheet to Chart

Postlight's React Google Sheet to Chart React component transforms Google Sheets to attractive charts in your webapp with minimal effort. Read all about it in this handy introduction.

Try it now at the demo site and check out the demo site GitHub repository.

Robo Chart preview

Installation

The package can be installed via NPM:

npm install @postlight/react-google-sheet-to-chart --save

# or

yarn add @postlight/react-google-sheet-to-chart

Usage

To use this component, you'll need a Google API key. You can generate one here.

Second, you'll need a Google Sheet containing the data you wish to plot. (Be sure to check out the spreadsheet format guidelines.)

Finally, import the React component and initialize it with at least three required props:

  • id: Spreadsheet ID, e.g. 1RE_JYUCXBXY2LNV5Tp5GegLnMue-CpfTVMxjdudZ8Js (extractable from a Google sheet URL)
  • sheet: Sheet name to parse data from, e.g. Sheet1
  • token: The Google API key you created above
import RoboChart from '@postlight/react-google-sheet-to-chart';

// ...your component code and then...

<RoboChart
  id="GOOGLE_SPREADSHEET_ID"
  sheet="Sheet1"
  token="GENERATED_GOOGLE_API_KEY"
/>

Quick setup in an app

yarn create react-app my-app
cd my-app
  • Install the package
yarn add @postlight/react-google-sheet-to-chart
  • Paste the following in App.js and replace GOOGLE_SPREADSHEET_ID and GENERATED_GOOGLE_API_KEY with appropriate values:
import React, { Component } from 'react';
import RoboChart from '@postlight/react-google-sheet-to-chart';
import './App.css';

const style = { width: '1200px', margin: '0 auto' };
class App extends Component {
  render() {
    return (
      <div style={style}>
        <RoboChart
          id="GOOGLE_SPREADSHEET_ID"
          sheet="Sheet1"
          token="GENERATED_GOOGLE_API_KEY"
        />
      </div>
    );
  }
}
export default App;
  • Start the project
yarn start

Optional props

  • start e.g. "A5" (start and end create a custom range for your data)
  • end e.g. "E15"
  • title This is the chart title, e.g. "My Accounts"
  • flipAxis default: {false}
  • startFrom default: {0}
  • stacked Use only with type bar, default: {false}
  • type default: "line", should be one of: "line", "bar", "horizontalBar", "pie", "semi-pie", "doughnut", "semi-doughnut"
  • colors e.g. {['#a1a1a1', '#434343', '#ff0055']}
  • xsuffix Add a suffix to x-Axis labels, e.g. " USD"
  • ysuffix Add a suffix to y-Axis labels

Example:

<RoboChart
  id="GOOGLE_SPREADSHEET_ID"
  sheet="Companies Values"
  token="GENERATED_GOOGLE_API_KEY"
  type="semi-pie"
  title="Companies values in Billion $"
  colors={['#a1a1a1', '#995500', '#990055', '#009955']}
/>

Robo Chart preview

Spreadsheet format

In order to successfuly generate a chart, the Spreadsheet should have Row titles, Column titles and Values, example:

Spreadsheet example

License

Licensed under either of the below, at your preference:

Contributing

Unless it is explicitly stated otherwise, any contribution intentionally submitted for inclusion in the work, as defined in the Apache-2.0 license, shall be dual licensed as above without any additional terms or conditions.


🔬 A Labs project from your friends at Postlight. Happy coding!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].