lbry-desktop/ui/component/fileViewCountInline/index.js
infinite-persistence 652ec4b69b
Fix memo: makeSelectViewCountForUri, makeSelectSubCountForUri
- switch to a lighter selectClaimIdForUri
- also, these 2 don't need to memo because they are just simple accessors.
2021-11-16 08:15:24 +08:00

15 lines
501 B
JavaScript

import { connect } from 'react-redux';
import { selectClaimForUri } from 'redux/selectors/claims';
import { selectViewCountForUri } from 'lbryinc';
import { selectLanguage } from 'redux/selectors/settings';
import FileViewCountInline from './view';
const select = (state, props) => {
return {
claim: selectClaimForUri(state, props.uri),
viewCount: selectViewCountForUri(state, props.uri),
lang: selectLanguage(state),
};
};
export default connect(select, null)(FileViewCountInline);