English | ็ฎไฝไธญๆ
๐ Quickly create Halo plugin development templates
A scaffolding tool for creating Halo plugin projects with modern development setup.
- ๐ฏ Interactive CLI - Guided project setup with prompts
- ๐๏ธ Modern Build Tools - Choose between Vite or Rsbuild for UI development
- ๐ฆ Complete Project Structure - Pre-configured Gradle build, UI setup, and plugin manifest
- ๐ TypeScript Support - Full TypeScript configuration for UI development
Create a new Halo plugin project using any of the following commands:
# npm npm create halo-plugin npm create halo-plugin my-plugin # pnpm (recommended) pnpm create halo-plugin pnpm create halo-plugin my-plugin # yarn yarn create halo-plugin yarn create halo-plugin my-plugin # npx npx create-halo-plugin npx create-halo-plugin my-plugin
pnpm create halo-plugin
# Creates a directory named "plugin-{your-plugin-name}"
pnpm create halo-plugin my-awesome-plugin
# Creates the project in "./my-awesome-plugin" directory
The CLI will guide you through the setup process:
๐ Welcome to Halo Plugin Creator! โ Plugin name: โบ my-awesome-plugin โ Domain (for group and package name): โบ com.example โ Author name: โบ John Doe โ Choose UI build tool: โบ Vite ๐ Project Configuration: Name: my-awesome-plugin Domain: com.example Package: com.example.myawesomeplugin Author: John Doe UI Tool: vite Output Directory: /path/to/my-awesome-plugin โ Create project? โบ yes
The generated project includes:
my-plugin/ โโโ src/ โ โโโ main/ โ โ โโโ java/ โ โ โ โโโ com/example/myplugin/ โ โ โ โโโ MyPluginPlugin.java โ โ โโโ resources/ โ โ โโโ plugin.yaml โ โ โโโ logo.png โ โโโ test/ โ โโโ java/ โ โโโ com/example/myplugin/ โ โโโ MyPluginPluginTest.java โโโ ui/ โ โโโ src/ โ โ โโโ index.ts โ โ โโโ views/ โ โ โโโ assets/ โ โโโ package.json โ โโโ vite.config.ts (or rsbuild.config.ts) โ โโโ tsconfig.json โโโ build.gradle โโโ settings.gradle โโโ gradlew โโโ README.md
After creating your project:
# Navigate to your project cd my-plugin # Start Halo development server ./gradlew haloServer # In another terminal, start UI development cd ui pnpm dev
- Node.js >= 18.0.0
- Java >= 21
- Halo >= 2.21.0
Plugin names must follow this pattern:
- Start and end with alphanumeric characters (a-z, 0-9)
- Can contain hyphens (-) and dots (.) in the middle
- Only lowercase letters allowed
- Examples:
my-plugin
,blog.comment
,user-management
Choose between two modern build tools:
- ๐ง Simple configuration
- ๐ฆ Optimized builds
- ๐ Rspack-based for speed
- ๐ ๏ธ Rich plugin ecosystem
- ๐ Better build performance
- ๐ฆ Code splitting, suitable for larger plugin projects
# Show help npx create-halo-plugin --help # Show version npx create-halo-plugin --version
We welcome contributions! Please see our Contributing Guide for details.
- Halo - Powerful and easy-to-use open source website builder
- Halo Documentation - Official documentation
- Plugin Development Guide