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