Skip to content

Commit 0dc2a24

Browse files
authored
Merge pull request #155 from jdupont/ElementPropTypes
Fix issue #152 by changing prop type for element.
2 parents 64161ed + fb85733 commit 0dc2a24

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ import InfiniteScroll from 'react-infinite-scroller';
6060

6161
| Name | Type | Default | Description|
6262
|:---- |:---- |:---- |:----|
63-
| `element` | `String` | `'div'` | Name of the element that the component should render as.|
63+
| `element` | `Component` | `'div'` | Name of the element that the component should render as.|
6464
| `hasMore` | `Boolean` | `false` | Whether there are more items to be loaded. Event listeners are removed if `false`.|
6565
| `initialLoad` | `Boolean` | `true` | Whether the component should load the first set of items.|
6666
| `isReverse` | `Boolean` | `false` | Whether new items should be loaded when user scrolls to the top of the scrollable area.|

dist/InfiniteScroll.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ var InfiniteScroll = (function(_Component) {
318318

319319
InfiniteScroll.propTypes = {
320320
children: _propTypes2.default.node.isRequired,
321-
element: _propTypes2.default.string,
321+
element: _propTypes2.default.node,
322322
hasMore: _propTypes2.default.bool,
323323
initialLoad: _propTypes2.default.bool,
324324
isReverse: _propTypes2.default.bool,

src/InfiniteScroll.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import PropTypes from 'prop-types';
44
export default class InfiniteScroll extends Component {
55
static propTypes = {
66
children: PropTypes.node.isRequired,
7-
element: PropTypes.string,
7+
element: PropTypes.node,
88
hasMore: PropTypes.bool,
99
initialLoad: PropTypes.bool,
1010
isReverse: PropTypes.bool,

0 commit comments

Comments
 (0)