-
Notifications
You must be signed in to change notification settings - Fork 346
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Import prop-types and demo fixed (#135)
* prop-types import added, React.PropTypes -> Proptypes * div id fixed at index.js, imports fixed and state to functional component
- Loading branch information
1 parent
5c2b137
commit a819296
Showing
4 changed files
with
60 additions
and
61 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,18 @@ | ||
import React from 'react'; | ||
import { render } from 'react-dom'; | ||
import { Chart } from 'react-google-charts'; | ||
import Chart from '../../src/components/Chart'; | ||
|
||
export default class App extends React.Component { | ||
render() { | ||
return ( | ||
<div className={'my-pretty-chart-container'}> | ||
<Chart | ||
chartType="ScatterChart" | ||
data={[['Age', 'Weight'], [8, 12], [4, 5.5], [1, 2]]} | ||
options={{}} | ||
graph_id="ScatterChart" | ||
width="100%" | ||
height="400px" | ||
legend_toggle | ||
/> | ||
</div> | ||
); | ||
} | ||
} | ||
const App = () => ( | ||
<div className={'my-pretty-chart-container'}> | ||
<Chart | ||
chartType="ScatterChart" | ||
data={[['Age', 'Weight'], [8, 12], [4, 5.5], [1, 2]]} | ||
options={{}} | ||
graph_id="ScatterChart" | ||
width="100%" | ||
height="400px" | ||
legend_toggle | ||
/> | ||
</div> | ||
); | ||
|
||
export default App; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters