Reactivesearch: ReactiveList > scrollTarget should/could also accept node

Created on 19 Jul 2019  Â·  4Comments  Â·  Source: appbaseio/reactivesearch

For the moment scrollTarget only accepts id of the container you wish to apply infinite loading on.

It could be great to be able to give a node, like a react ref or a document.querySelector().

enhancement good first issue hacktoberfest web

Most helpful comment

Thanks @felubra for working on this 💯

@kud This will be released with the next version of Reactivesearch ✨

All 4 comments

Hey, @kud thanks for the idea. It will be great if you can describe a scenario in which this enhancement would fit great.

<ReactiveList
            componentId="AmendmentsResult"
            scrollTarget={this.asideRef.current}
>

<AsideBox ref={this.asideRef}>
          {aside}
</AsideBox>

or

<ReactiveList
            componentId="AmendmentsResult"
            scrollTarget={document.querySelector(".org-MyElement")}
>

<AsideBox class="org-MyElement">
          {aside}
</AsideBox>

Awesome this is really great 💥 Are you open for creating a PR for this ?

Thanks @felubra for working on this 💯

@kud This will be released with the next version of Reactivesearch ✨

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ymzoughi picture ymzoughi  Â·  4Comments

carlopascual picture carlopascual  Â·  3Comments

jkhaui picture jkhaui  Â·  3Comments

davidklebanoff picture davidklebanoff  Â·  4Comments

scheiblr picture scheiblr  Â·  3Comments