collective / collective.solr

Solr search engine integration for Plone
https://pypi.org/project/collective.solr/
22 stars 46 forks source link

Disable react based search #244

Closed pbauer closed 2 years ago

pbauer commented 4 years ago

The react-based search-page has very little benefit over the default in Plone and is missing i18n and quicksearch.

I removed the react-based search-page and the search-viewlet in my last project by adding the following to a overrides.zcml. This restores the default behavior and still uses solr.

    <browser:page
        name="search"
        class="Products.CMFPlone.browser.search.Search"
        permission="zope2.View"
        for="plone.app.layout.navigation.interfaces.INavigationRoot"
        template="templates/search.pt"
        layer="collective.solr.browser.interfaces.IThemeSpecific"
        />

    <browser:viewlet
        name="plone.searchbox"
        manager="plone.app.layout.viewlets.interfaces.IPortalHeader"
        class="plone.app.layout.viewlets.common.SearchBoxViewlet"
        permission="zope2.View"
        layer="collective.solr.browser.interfaces.IThemeSpecific"
        />

I wonder: Why would anyone use the react-based search page and viewlet? Should we remove them?

sauzher commented 4 years ago

+1 for removal.

tisto commented 4 years ago

@pbauer the react search allows the user to see search results within milliseconds. You get a Solr-like search experience on top of a standard Plone for free. The React search is also a good base to write a customized search (which we do almost 100% of the time). This was the reason we shared the React search. We actually never used it in any project as far as I know. The way to go IMHO is to solve the open problems of the React search.