npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

directus-extension-typesense

v1.1.0

Published

Typesense search engine features for directus.

Readme

directus-extension-typesense

Integrates Typesense with Directus.

  • 😌 Easy to setup and opt-out again. No additional tables/data structure needed.
  • 🔒 Keeps your data secure as it adds content to the search index based on a policy (public policy by default).
  • 🌐 Supports multilingual content by adding translated fields to index collection.
  • 🪨 Handles bulk data imports/updates.

Getting started

  1. You will need a running Typesense instance.
  2. Install this extension (for now only made for use on self-hosted instances).
  3. Configure directus to use typesense by setting the TYPESENSE_URL and TYPESENSE_SECRET environment variables.

Minimal example using docker compose:

# Dockerfile
FROM directus/directus

USER root
RUN corepack enable
USER node

RUN pnpm install directus-extension-typesense
# docker-compose.yml
services:
  directus:
    platform: linux/amd64
    build:
      context: ./
    ports:
      - 127.0.0.1:8055:8055
    environment:
      ADMIN_EMAIL: [email protected]
      ADMIN_PASSWORD: d1r3ctu5
      EXTENSIONS_AUTO_RELOAD: true
      DB_FILENAME: /directus/database/db.sqlite
      TYPESENSE_URL: "http://typesense:8108"
      TYPESENSE_API_KEY: "secret"

  typesense:
    platform: linux/amd64
    image: typesense/typesense:29.0
    ports:
      - 127.0.0.1:8108:8108
    volumes:
      - ./typesense-data:/data
    environment:
      TYPESENSE_API_KEY: "secret"
      TYPESENSE_DATA_DIR: "/data"
      TYPESENSE_ENABLE_CORS: true

Policy based indexing

By default this extension will check the public policy to decide whether data will be added to the search index or not. You can change this though by setting the TYPESENSE_POLICY environemnt variable to the id of the policy you want it to respect.

Multilingual content

If you setup content translations, this extension will fetch the translations and add them as localised fields to the documents.

// GET <typesense_url>/collections/article/documents/1
{
  "id": 1,
  "title_en": "No one is illegal",
  "title_es": "Nadie es ilegal",
  "title_fa": "هیچ انسانی غیرقانونی نیست"
}

Future goals

  • [ ] Respect more fine-grained field permissions
  • [ ] Refactor in order to have dedicated operations to manually control index building
  • [ ] Sorting of fields