Module: search/uijet-search


uijet-search search module.




Constructor for the search index class.

Available options:

  • fields {Object}: a map of field names of the documents to search against. Currently values are ignored.
  • ref {string}: a field in the searched documents to use as reference for results. Defaults to null which uses the doc itself as ref, instead of a value of its field.
  • query_flags {string}: RegExp's flags to use when performing search. Defaults to 'i'. See "Advanced Searching With Flags"
  • clean_term {function}: method for cleaning the raw input term before searching.



modules/search/uijet-search.js, line 55

Adds more documents to the index to search in.

Name Type Description
docs Array

documents to add to the index.

modules/search/uijet-search.js, line 66

Performs search using given term and returns list of results.

Name Type Description
term string

the search term to use for searching the documents.

ref string | null optional

override the ref option just for this search.

list. Can be a list of documents or values specified by ref option.


modules/search/uijet-search.js, line 44

Sets documents to populate the index.

Name Type Description
docs Array

documents to search in.