Skip to content

Playground ​

The repository includes a Nuxt app in playground/ that exercises the module against a real Typesense server.

bash
pnpm dev:prepare
pnpm dev          # http://localhost:3000

Set TYPESENSE_URL and TYPESENSE_API_KEY (an admin key, since the demos write data) before starting. The playground runs in server mode and uses the /api/typesense/* proxy routes.

Seed the test data ​

On the Overview page, Initialize Test Data creates the products, books and users collections with sample documents, plus a synonym set, a stopword set and a curation set (demo_synonyms, demo_stopwords, demo_curation). The synonym and curation sets are linked to products, because Typesense only applies them to a collection once they are linked. Clear All Data removes them again.

Pages ​

MenuPageWhat it shows
SearchSearch DemoLive product search with filters
SearchSearch PresetsRunning a search with a stored preset
TuningSynonyms & StopwordsCreate, list and delete synonym and stopword sets, then search with stopwords applied
TuningCurationCreate a curation set, link it to products, and see pinned or hidden results change
TuningStemmingImport a word to root dictionary and view its mappings (dictionaries cannot be deleted in Typesense)
DataCollectionsBrowse, create and delete collections
DataAliasesCreate, repoint and delete collection aliases
DataAnalyticsAnalytics rules and events
AdminInfoServer status and runtime configuration
AdminKey ManagementList, create and delete API keys
AdminAI ModelsList natural language search and conversation models (creating them needs a provider API key)
AdminOpenAPIThe generated OpenAPI description of the proxy routes, with a link to the JSON (enabled with openAPI: true)
AdminOperationsMetrics and stats, plus buttons for clear cache, compact DB, debug info and snapshot
ExamplesRunnable snippets for the main routes

WARNING

The operations buttons run against the configured Typesense server, and snapshots are written to that server's disk. Use a development instance.

Error display ​

Failed requests show the message Typesense returned (for example "Collection not found"). The playground reads it from error.data.message through the errorMessage() helper in playground/app/utils/errorMessage.ts.

Released under the MIT License.