Plugins

Setting Up Your Development Environment

This guide covers how to set up your development environment for plugin development.

Step 0: Prerequisites

To develop plugins optimally, you need to have a few things installed:

Step 1: Download the Plugin Template

After CLI installation, proceed to download the plugin template. This pre-configured project structure jumpstarts your plugin development, providing boilerplate code, configuration files, and directory structures. Execute the following command:

plugin-cli create <your plugin name here>

The CLI prompts you to name your Plugin and creates a folder with all necessary files to initiate a Plugin.

Step 2: Initialize Your Project

With the plugin template downloaded, it's time to initialize your project and tailor it to your requirements. Navigate to the directory where you downloaded the template and follow these steps:

  1. Install Dependencies:

Run the following command in your terminal to download all dependencies, including types for the functions served by the ctx variable inside the definePlugin function:

bun install