diff options
author | eug-vs <eug-vs@keemail.me> | 2020-07-03 17:06:28 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2020-07-03 17:06:28 +0300 |
commit | 9dfbf0377663d92a2f34ebe0cf435b473ee5445b (patch) | |
tree | 1974e2009a140304dd41e5696c6ab037108c827e /src/components/Feed/Feed.tsx | |
parent | b9ab4b1c608c7022d15a264ec123f2c1a476c33d (diff) | |
download | which-ui-9dfbf0377663d92a2f34ebe0cf435b473ee5445b.tar.gz |
style: fix eslint errors
Diffstat (limited to 'src/components/Feed/Feed.tsx')
-rw-r--r-- | src/components/Feed/Feed.tsx | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/components/Feed/Feed.tsx b/src/components/Feed/Feed.tsx index 785dd79..c532f45 100644 --- a/src/components/Feed/Feed.tsx +++ b/src/components/Feed/Feed.tsx @@ -1,8 +1,9 @@ import React from 'react'; import { Poll } from 'which-types'; -import PollCard from '../PollCard/PollCard'; import { WindowScroller, AutoSizer, List } from 'react-virtualized'; +import PollCard from '../PollCard/PollCard'; + interface PropTypes { polls: Poll[]; } @@ -14,21 +15,26 @@ interface RenderPropTypes { } const Feed: React.FC<PropTypes> = ({ polls }) => { - const RenderItem: React.FC<RenderPropTypes> = ({ index, style, key }) => { const poll = polls[index]; return ( <div key={key} style={style}> <PollCard initialPoll={poll} /> </div> - ) + ); }; return ( <WindowScroller> - {({height, isScrolling, registerChild, onChildScroll, scrollTop}) => ( + {({ + height, + isScrolling, + registerChild, + onChildScroll, + scrollTop + }) => ( <AutoSizer disableHeight> - {({width}) => ( + {({ width }) => ( <div ref={registerChild}> <List autoHeight |