FieldSearchIndex
Defined in: packages/core/src/fields/baseTypes.ts:48
Full-text search index configuration for a string field. Not a base field
option: only field types that declare their own searchIndex property
(text, textarea, email) accept it. The field it is defined on becomes
the index’s searchField.
Example
Section titled “Example”title: text({ searchIndex: { name: "search_title", filterFields: ["status", "author"] } })// Generates: .searchIndex("search_title", { searchField: "title", filterFields: ["status", "author"] })Properties
Section titled “Properties”filterFields
Section titled “filterFields”filterFields:
string[]
Defined in: packages/core/src/fields/baseTypes.ts:55
Fields to filter search results by. String array — validated at runtime against collection field names.
name:
string
Defined in: packages/core/src/fields/baseTypes.ts:50
Search index name (must be unique within the collection).