@texthill/localstorage

A store implementation to store the indexes for texthill in localstorage

Usage no npm install needed!

<script type="module">
  import texthillLocalstorage from 'https://cdn.skypack.dev/@texthill/localstorage';
</script>

README

TextHill localstorage

A search engine written in typescript, can be used in the browser, with node.js and deno.

Look at this example below to get you started.

const bh = new TextHill(new LocalStorageStore());
const feed = async () => {
    await bh.feedDoc("hello world", "some hello world for feeding");

    const results = await bh.search("feeding"); 
}

Or remove the document from the index.

const bh = new TextHill(new LocalStorageStore());
bh.removeDoc("hello world").then(_ => console.log('succesfully removed'))