2
votes

If I have a movie search application and am using ReactiveSearch with Elasticsearch. I'd like to integrate Server Side Rendering (SSR) into the app but am trying to make sure I understand implementation first before I start.

I want my Autocomplete component to be the home page of the website and I just want to render the search box as quickly as possible. I don't necessarily want to render results within milliseconds of user coming to the page - I just want to show them them content quickly.

Do I need to implement SSR for ReactiveSearch too?

OR

Is React SSR enough?

1

1 Answers

3
votes

The primary advantage of SSR in ReactiveSearch is the results are pre-fetched on the server and populated in the ReactiveSearch store which renders them instantly as soon as the page is fetched.

If your usecase does not need the results to be server rendered then just SSR for other react components would be fine.

Note that when you use SSR for reactivesearch the server takes slighly longer to respond since it has to fetch the data from elasticsearch. So, at times SSR might not be the perfect usecase (especially if you're not interested in server rendering the results).