Skip to content

maizzle/cli

Repository files navigation

Maizzle CLI

The CLI tool for Maizzle

Version Build Downloads License

Installation

You may use maizzle directly, with npx:

npx maizzle new

This will start the interactive setup:

Maizzle CLI preview

Alternatively, you can install it globally:

npm install -g maizzle

Usage

Create a new project

Interactive mode:

maizzle new

Scaffold a project from a GitHub starter repo (user/repo):

maizzle new maizzle/maizzle

Specify a target directory:

maizzle new maizzle/maizzle my-project

Automatically install dependencies:

maizzle new maizzle/maizzle my-project --install

Use a specific package manager:

maizzle new maizzle/maizzle my-project --install --pm pnpm

Development

Start a local development server:

maizzle serve

maizzle dev is an alias for maizzle serve.

Build

Build emails for production:

maizzle build

Options

Option Description
-c, --config <path> Path to a Maizzle config file
-o, --output <path> Output directory
--dir <path> Source directory for email templates
--ext <extension> Output file extension
--pretty Pretty-print HTML output
--minify Minify HTML output
--plaintext Generate plaintext versions alongside HTML

When -c, --config is set, the override flags (-o, --dir, --ext, --pretty, --minify, --plaintext) are ignored — your config file is used as-is.

Prepare

Generate IDE type definitions in .maizzle/. Run after adding new components or composables when you want auto-import types to update without starting the dev server:

maizzle prepare

Scaffolding

You may use the make command to scaffold new files for your project.

Template

Create a new email template:

maizzle make:template [filepath]

Layout

Create a new email layout with the base HTML email structure and a default slot:

maizzle make:layout [filepath]

Component

Create a new component with a slot and props:

maizzle make:component [filepath]

Config

Create a new maizzle.config.ts file:

maizzle make:config [name]

Documentation

Maizzle documentation is available at https://maizzle.com

License

The Maizzle framework is open-sourced software licensed under the MIT license.