Formatting

This commit is contained in:
squidfunk 2022-12-11 15:56:47 +01:00
parent 24a3be8f04
commit 77528e7e64

View File

@ -26,19 +26,25 @@ import lunr from "lunr"
* Global types
* ------------------------------------------------------------------------- */
type Fields = "text" | "title" | "tags"
declare global {
namespace lunr {
/**
* Indexed fields
*/
type Fields = "text" | "title" | "tags"
/**
* Index - expose inverted index
*/
interface Index { // this is defined in the actual inverface...
interface Index {
invertedIndex: Record<string, unknown>
fields: Fields[]
}
/**
* Improve typings of query builder
*/
interface Builder {
field(
fieldName: string,