Skip to main content
This guide walks you through creating a Stratos plugin from scratch — a React component that appears in the Stratos sidebar with live reload during development.

Prerequisites

  • Node.js 20+
  • pnpm (recommended)
  • The Stratos app installed with developer mode (--dev flag) access

1. Scaffold your plugin

The fastest way to get started:
This prompts you for a plugin name, author, and type, then generates a ready-to-develop project with Tailwind CSS, TypeScript, and Vite preconfigured. Your project structure:
Install dependencies:

2. Understand the key files

plugin.json

Every plugin needs a manifest. The scaffolder generates this for you:
The id must be unique — lowercase alphanumeric and hyphens only. The type controls distribution: "airline" plugins are synced to all pilots by the VA; "user" plugins are installed individually.

vite.config.ts

createPluginConfig handles everything: externalising shared dependencies (React, TanStack Query, the SDK), ESM output format, asset copying, and dev server auto-connect. The vite option lets you add extra Vite config like Tailwind and React.
Keep react() in the plugins array — it’s required for the dev server, not just a convenience. The SDK injects a Fast Refresh preamble that imports /@react-refresh, which is only served when @vitejs/plugin-react is registered.

src/ui/index.tsx

Your plugin’s root component. Must be the default export:
The shell mounts this component at /plugins/my-plugin and wraps it with providers that supply plugin context, error boundaries, and theme.

3. Develop with live reload

Start the Stratos app in developer mode, log in, and select your airline. Then in your plugin directory:
You’ll see:
Your plugin appears in the Stratos sidebar immediately. Edit your code — changes auto-reload in about a second.

4. Bundle and deploy

When you’re ready to ship:
This builds your plugin, zips dist/ into bundle.zip, and uploads it to Skyvex automatically if you have an API token set. The scaffolder already added this script to your package.json. To enable automatic uploads, create an API token in your account at skyvexsoftware.com (Settings → API tokens) with the plugin:upload scope ticked, then set it as an environment variable:
Without the token, the command still creates bundle.zip for manual upload through the website. See Build & Deploy for CI/CD setup, release modes, and troubleshooting.

Adding a background module

If your plugin needs server-side functionality (Express routes, IPC handlers, database access), add a background module:
  1. Create src/background/index.ts:
  1. Update vite.config.ts:
  1. Add cross-env and update build scripts in package.json:
See Background Module for the full API reference.

Tips

  • Use useSimData with a select option to pull only the fields you need — avoids unnecessary re-renders on every simulator tick
  • Background modules are optional — most plugins only need a UI
  • Your plugin gets the same Tailwind setup as Stratos, so utility classes just work
  • The SDK is a dev dependency — Stratos provides React, TanStack Query, and Socket.io at runtime so your bundle stays small
  • Check the logs at Settings > Logs if something isn’t connecting

Next steps