Guide

Request caching

1min
klevu sdk automatically caches sent request to local memory for speedier results for same requests if you a system where same klevufetch is called multiple times, for example when focusing on input, it is much more convinient to get results from local memory than making same request to klevu api again and again this happens automatically without any configuration with 10 minutes cache if you wish disable or change the time of caching you change this with klevuconfig in your initialization import { klevuconfig } from "@klevu/core" klevuconfig init({ url "https //\<your server> ksearchnet com/cs/v2/search", apikey "klevu xxxxxxxxxxxxx", cachemaxttl 10000 // 10 seconds memory cache })import { klevuconfig } from "@klevu/core" klevuconfig init({ url "https //\<your server> ksearchnet com/cs/v2/search", apikey "klevu xxxxxxxxxxxxx", cachemaxttl 10000 // 10 seconds memory cache }) cache is cleared if user browser make a full page navigation in typical single page application this cache is not cleared when changing route