Repository navigation
Adding a Tool
Adding a tool takes four small steps. Most tools are under 40 lines.
Add an entry to src/lib/tools.js:
{
category: 'string', // one of the ids in `categories`
slug: 'my-tool', // the URL: /string/my-tool/
title: 'My Tool',
sidebarName: 'My Tool',
description: 'One sentence about what it does',
icon: 'magic' // a Bootstrap Icons name, without the "bi-" prefix
}The sidebar, search, home page, llms.txt, tools.json and the sitemap pick it up automatically.
Write a pure function and export it. Throw an Error with a friendly message for bad input.
export const reverseWords = (text) => text.split(/\s+/).reverse().join(' ');src/routes/string/my-tool/+page.svelte. For text in, text out, use ToolPage:
<script>
import ToolPage from "../../../components/ToolPage.svelte";
import { reverseWords } from "#lib/textUtils.js";
let text = $state("");
const actions = [{ label: "Reverse words", transform: reverseWords }];
</script>
<ToolPage title="My Tool" description="Reverse the order of words." bind:value={text} {actions} />For a live preview on the right, use ConvertPage with a convert(text) function. For anything custom, write a normal page and reuse OutputCard, StatRows and ResultList.
Add a test next to the logic, for example in src/lib/textUtils.test.js, and run:
bun run test
bun run buildAdd an entry to src/lib/agentTools.js with a name, description, JSON Schema and run function. It is then exposed through WebMCP and the MCP server. See Agent Support.
- Tools must work without a server and never upload user input.
- Keep secrets out of examples and outputs.
- Support light and dark mode and phone-sized screens.
- Commit messages are imperative ("Add CSS minifier tool") and signed off with
git commit -s.
Mools (Maling-IT Online Tools) is open source under the MIT license. Found a mistake on a wiki page? Edit it, or open an issue.
The project
Using Mools
Building Mools