mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-11 03:24:16 +00:00
added contentsRef
This commit is contained in:
parent
8c280afbf2
commit
a5fd4ecbf0
@ -1,6 +1,5 @@
|
|||||||
import React from "react"
|
import React from "react"
|
||||||
import { Skeleton } from "antd"
|
import { Skeleton } from "antd"
|
||||||
import { Icons } from "components/Icons"
|
|
||||||
|
|
||||||
import { PostsList } from "components"
|
import { PostsList } from "components"
|
||||||
import Post from "models/post"
|
import Post from "models/post"
|
||||||
@ -21,6 +20,8 @@ export default class UserPosts extends React.Component {
|
|||||||
posts: [],
|
posts: [],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
contentsRef = React.createRef()
|
||||||
|
|
||||||
loadData = async ({
|
loadData = async ({
|
||||||
trim,
|
trim,
|
||||||
replace = false
|
replace = false
|
||||||
@ -76,6 +77,7 @@ export default class UserPosts extends React.Component {
|
|||||||
emptyListRender={emptyListRender}
|
emptyListRender={emptyListRender}
|
||||||
onLoadMore={this.loadData}
|
onLoadMore={this.loadData}
|
||||||
posts={this.state.posts}
|
posts={this.state.posts}
|
||||||
|
ref={this.contentsRef}
|
||||||
/>
|
/>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user