Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: initv4 migration #360

Draft
wants to merge 1 commit into
base: dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion content/docs/pipelines/API/reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ Use a pre-built stage from Appbase.

**Following values are supported for this field**

`authorization`, `elasticsearchQuery`, `reactivesearchQuery`, `useCache`, `recordAnalytics`, `promoteResults`, `hideResults`, `customData`, `replaceSearchTerm`, `addFilter`, `removeWords`, `replaceWords`, `searchRelevancy`, `kNN`, `httpRequest`, `mongoDBQuery`, `solrQuery`, `recordClick`, `recordConversion`, `recordFavorite`, `recordSaveSearch`, `searchboxPreferences`, `boost`
`authorization`, `elasticsearchQuery`, `reactivesearchQuery`, `useCache`, `recordAnalytics`, `promoteResults`, `hideResults`, `customData`, `replaceSearchTerm`, `addFilter`, `removeWords`, `replaceWords`, `searchRelevancy`, `kNN`, `httpRequest`, `mongoDBQuery`, `solrQuery`, `zincQuery`, `recordClick`, `recordConversion`, `recordFavorite`, `recordSaveSearch`, `searchboxPreferences`, `boost`, `marklogicQuery`

## Trigger Expression

Expand Down
53 changes: 53 additions & 0 deletions content/docs/reactivesearch/v3/advanced/migration-v4.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
---
title: 'ReactiveSearch: Migration Guide (v4)'
meta_title: 'ReactiveSearch: Migration Guide (v4)'
meta_description: 'This guide will give you a brief about all the changes in the 4.x release of ReactiveSearch.'
keywords:
- reactivesearch
- migrationguide
- appbase
- elasticsearch
sidebar: 'docs'
nestedSidebar: 'web-reactivesearch'
---

ReactiveSearch and ReactiveMaps are fully compatible with React 18.x and above with the 4.x releases. This release comes after the feedback we have gathered from the iterative deployment of reactivesearch in production for the dozens of our clients over the last year. In this version, we have changed the way certain props behave, and included new components. This guide will give you a brief about all the changes.

## ReactiveSearch

### Removal of FE query generation
In this release we have removed the front-end query generation, we discourage the use of front-end queries to search backend which is a security risk.
We're using the declarative [Reactivesearch API](docs/search/reactivesearch-api/) to query the search backend. You can either self-host the OSS version of [Reactivesearch API Server](https://github.com/appbaseio/reactivesearch-api) or use the Appbase services.

### Removal of `DataSearch` & `CategorySearch` components
In 3.x we had two components for auto-suggestions, `DataSearch` & `CategorySearch` (to display category suggestions). In 4.x we have only one component named [SearchBox](docs/reactivesearch/v3/search/searchbox/) to implement auto-suggestions UI.

**v3.x:**

```jsx
<DataSearch
componentId="Search"
dataField={['title', 'description']}
/>
```

**v4.x:**

```jsx
<SearchBox
componentId="Search"
dataField={['title', 'description']}
/>
```

### Removal of Deprecated props
We have also removed the following deprecated props:

| <p style="margin: 0px;" class="table-header-text">Prop Name</p> | <p style="margin: 0px;" class="table-header-text">Component</p> | <p style="margin: 0px;" class="table-header-text">Alternative</p> |
| ------ | --------------------------- | -------- |
| `analyticsConfig` | `ReactiveBase` | `reactivesearchAPIConfig` |
| `appbaseConfig` | `ReactiveBase` | `reactivesearchAPIConfig` |
| `analytics` | `ReactiveBase` | `reactivesearchAPIConfig.recordAnalytics` |
| `enableAppbase` | `ReactiveBase` | `_` |
| `triggerAnalytics` | `ReactiveList.renderItem` | `triggerClickAnalytics` |
| `aggregationField` | `All Components` | `distinctField` |
Original file line number Diff line number Diff line change
Expand Up @@ -1667,7 +1667,7 @@ Following example indicates how to use this field to use kNN reordering with Ope

**Following values are supported for this field**

``elasticsearch``, ``opensearch``, ``mongodb``, ``solr``, ``zinc``
``elasticsearch``, ``opensearch``, ``mongodb``, ``solr``, ``zinc``, ``marklogic``

## metadata

Expand Down
2 changes: 1 addition & 1 deletion content/docs/search/reactivesearch-api/reference/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -1658,7 +1658,7 @@ Following example indicates how to use this field to use kNN reordering with Ope

**Following values are supported for this field**

`elasticsearch`, `opensearch`, `mongodb`, `solr`, `zinc`
`elasticsearch`, `opensearch`, `mongodb`, `solr`, `zinc`, `marklogic`

## metadata

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1667,7 +1667,7 @@ Following example indicates how to use this field to use kNN reordering with Ope

**Following values are supported for this field**

````elasticsearch````, ````opensearch````, ````mongodb````, ````solr````, ````zinc````
````elasticsearch````, ````opensearch````, ````mongodb````, ````solr````, ````zinc````, ````marklogic````

## metadata

Expand Down
2 changes: 1 addition & 1 deletion content/docs/search/reactivesearch-api/reference/solr.md
Original file line number Diff line number Diff line change
Expand Up @@ -960,7 +960,7 @@ Following example indicates how to use this field to use kNN reordering with Ope

**Following values are supported for this field**

```elasticsearch```, ```opensearch```, ```mongodb```, ```solr```, ```zinc```
```elasticsearch```, ```opensearch```, ```mongodb```, ```solr```, ```zinc```, ```marklogic```

## metadata

Expand Down
4 changes: 3 additions & 1 deletion src/data/sidebars/web-reactivesearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,10 @@
link: /docs/reactivesearch/v3/advanced/ssr/
- title: Components Usage
link: /docs/reactivesearch/v3/advanced/usage/
- title: Migration Guide
- title: Migration Guide (v3)
link: /docs/reactivesearch/v3/advanced/migration/
- title: Migration Guide (v4)
link: /docs/reactivesearch/v3/advanced/migration-v4/
- title: Advanced Guides
link: /docs/reactivesearch/v3/advanced/guides/
- title: Search and Click Analytics
Expand Down