From 04e92a0c35c28475ea6b860559154a89ab0cf2c8 Mon Sep 17 00:00:00 2001 From: Andrew Taft <11670864+ataft@users.noreply.github.com> Date: Wed, 8 Jul 2020 12:02:40 -0700 Subject: [PATCH] Update bloodhound.md Add info for `cache` and `clearRemoteCache()` --- doc/bloodhound.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/doc/bloodhound.md b/doc/bloodhound.md index 0541288031..e3709fe8c1 100644 --- a/doc/bloodhound.md +++ b/doc/bloodhound.md @@ -159,6 +159,14 @@ Clears the internal search index that's powered by `local`, `prefetch`, and engine.clear(); ``` +#### Bloodhound#clearRemoteCache() + +Clears the remote transport cache. + +```javascript +engine.clearRemoteCache(); +``` + ### Options When instantiating a Bloodhound suggestion engine, there are a number of @@ -293,6 +301,8 @@ When configuring `remote`, the following options are available. * `rateLimitWait` – The time interval in milliseconds that will be used by `rateLimitBy`. Defaults to `300`. +* `cache` – Cache remote results. Defaults to `true`. + * `transform` – A function with the signature `transform(response)` that allows you to transform the remote response before the Bloodhound instance operates on it. Defaults to the [identity function].