Skip to content

Commit

Permalink
added weatherlist
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenGrider committed Jan 3, 2016
1 parent 76f9b96 commit 09d4d3f
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
2 changes: 2 additions & 0 deletions weather/src/components/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@ import React from 'react';
import { Component } from 'react';

import SearchBar from '../containers/search_bar';
import WeatherList from '../containers/weather_list';

export default class App extends Component {
render() {
return (
<div>
<SearchBar />
<WeatherList />
</div>
);
}
Expand Down
27 changes: 27 additions & 0 deletions weather/src/containers/weather_list.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import React, { Component } from 'react';
import { connect } from 'react-redux';

class WeatherList extends Component {
render() {
return (
<table className="table table-hover">
<thead>
<tr>
<th>City</th>
<th>Temperature</th>
<th>Pressure</th>
<th>Humidity</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
);
}
}

function mapStateToProps({ weather }) {
return { weather };
}

export default connect(mapStateToProps)(WeatherList);

0 comments on commit 09d4d3f

Please sign in to comment.