Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/aurelienbobenrieth/gadget/llms.txt

Use this file to discover all available pages before exploring further.

The Gadget Developer Tools monorepo provides essential tooling for Gadget development. It includes two complementary packages: an ESLint plugin for validating Gadget action files and a design system for building consistent, polished UIs.

Packages

eslint-plugin-gadget

ESLint rules for Gadget action files. Catches invalid options, params, timeout values, and runtime issues before they hit production. Key features:
  • 16 rules covering options validation, params validation, runtime safety, and enqueue patterns
  • Auto-fixes for common issues (invalid timeout values, numeric separators, template literals)
  • File pattern detection - rules only activate on Gadget action files
  • Two preset configs: recommended (warnings + errors) and strict (all errors)
  • Compatible with ESLint v9+ flat config
Install:
pnpm add -D @aurelienbbn/eslint-plugin-gadget eslint
Use cases:
  • Validate ActionOptions exports contain only JSON-serializable values
  • Enforce timeout constraints (max 15 minutes, 5 seconds for transactional actions)
  • Prevent await handle.result() in action run functions (causes transaction timeouts)
  • Require explicit retries in api.enqueue() calls (Gadget defaults to 6)
  • Catch unsupported JSON Schema features in params exports

gadget-ui

Design system and component library built with React, Tailwind CSS, and class-variance-authority. Features a dark-first, neo-skeuomorphic aesthetic inspired by Gadget’s visual identity. Key features:
  • 8 React components with variants (Button, Badge, Card, CodeBlock, Callout, and more)
  • Tailwind CSS preset with design tokens mapped to CSS custom properties
  • Dark and light theme support via data-theme attribute
  • Global CSS with Inter and Inconsolata fonts, semantic color system
  • cn() utility for merging class names with tailwind-merge
Install:
pnpm add @aurelienbbn/gadget-ui react react-dom tailwindcss
Use cases:
  • Build documentation sites with consistent Gadget branding
  • Create dashboards and admin UIs with pre-built components
  • Leverage semantic design tokens for theming and customization
  • Syntax highlighting with Shiki integration

Monorepo structure

gadget/
  packages/
    eslint-plugin-gadget/   # ESLint plugin (16 rules)
    gadget-ui/              # Design system (components, tokens, preset)
  apps/
    eslint-plugin-gadget-docs/  # Astro + Starlight documentation site
Both packages are built with tsup and output ESM, CJS, and TypeScript definitions. The monorepo uses pnpm workspaces and Changesets for versioning.

Requirements

  • Node: 18 or higher
  • Package manager: pnpm (recommended), npm, or yarn
  • eslint-plugin-gadget: ESLint v9+, @typescript-eslint/utils v8+
  • gadget-ui: React 18+, Tailwind CSS 3.4+

Next steps

Quickstart

Get both packages set up in under 5 minutes

ESLint Plugin

Install and configure the ESLint plugin

UI Components

Set up the design system in your project

Theming

Learn about design tokens and theme switching

License

Both packages are MIT licensed.

Build docs developers (and LLMs) love