Using from CDN

First, you have to directly include Mithril and MiniSearch for now:

<script src=""></script>
<script src=""></script>

If you want to use our CSS, you'll also need to include the Google Font it uses:

<link href="" rel="stylesheet" />
<link href=",wght@0,400;0,600;0,700;0,400&display=swap" rel="stylesheet" />

Then you just need some JavaScript to import and call setup with a built-in or custom backend adapter:

<script type="module">
  import {setup, BrowserBackend} from "";
  setup(document, document.body, new BrowserBackend());

Building from Source

You can build from source by cloning or forking the project and installing Deno. Then you can run:

deno task bundle

This will produce a JS file you can use at web/static/lib/treehouse.min.js.

For development or debugging, you can run:

deno task serve

This will build and serve this website locally, including the live demo site at localhost:9000/demo, which will use and watch for changes in the lib source.

Customizing the Frontend

The easiest aspect to customize is the look and feel, which you can do with custom CSS. Our CSS design system is built with custom properties, so you can include your own CSS and just override them with basic CSS.

Further customization might require you to fork and change the source. The source code is very straight forward, but learn more in the Developer Guide.

Lastly, of course, you can implement a custom backend adapter. Although there are just a few things to change this way, more extension points will be exposed in the future so you won't have to change source. Let us know in the forum what kind of extension points you'd like!

Stay in touch

Sign up for our mailing list to receive updates on the project.

We don't share your email.