2019-08-07 01:57:52 +10:00
|
|
|
import { connect } from 'react-redux';
|
2022-02-25 10:34:33 +11:00
|
|
|
import { fetchTrendingHashtags } from 'mastodon/actions/trends';
|
2019-08-07 01:57:52 +10:00
|
|
|
import Trends from '../components/trends';
|
|
|
|
|
|
|
|
const mapStateToProps = state => ({
|
2022-02-25 10:34:33 +11:00
|
|
|
trends: state.getIn(['trends', 'tags', 'items']),
|
2019-08-07 01:57:52 +10:00
|
|
|
});
|
|
|
|
|
|
|
|
const mapDispatchToProps = dispatch => ({
|
2022-02-25 10:34:33 +11:00
|
|
|
fetchTrends: () => dispatch(fetchTrendingHashtags()),
|
2019-08-07 01:57:52 +10:00
|
|
|
});
|
|
|
|
|
|
|
|
export default connect(mapStateToProps, mapDispatchToProps)(Trends);
|