search

package
v0.0.0-...-8655328 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 6, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultLimit = 24

Variables

This section is empty.

Functions

This section is empty.

Types

type SearchParams

type SearchParams struct {
	Term string
}

type Searcher

type Searcher interface {
	// SearchDocs is used to search the index. It is passed a query and the max number
	// of results to return.
	// If limit is 0, the default limit is used.
	// A slice of post ids is returned
	SearchDocs(ctx context.Context, params SearchParams) (paths []string, err error)

	// IndexDocs indexes the entire docs directory
	// The argument of the function is the directory to index
	// This should clear all previous indexe
	IndexDocs(ctx context.Context, store fs.FS) error
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL