UNPKG

create-marp-slides

Version:

CLI tool for scaffolding Marp presentation projects with GitHub Pages deployment

118 lines (83 loc) • 2.87 kB
# create-marp-slides [![npm version](https://badge.fury.io/js/create-marp-slides.svg)](https://badge.fury.io/js/create-marp-slides) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) CLI tool for scaffolding Marp presentation projects with GitHub Pages deployment. ## Features - šŸš€ **Quick Setup**: Create a new Marp presentation project in seconds - šŸ“ **Markdown-based**: Write slides in Markdown with Marp syntax - šŸŽØ **Beautiful Themes**: Built-in Marp themes and styling - šŸ”„ **Auto-deploy**: GitHub Actions workflow for automatic deployment to GitHub Pages - šŸ“± **Responsive**: Mobile-friendly slide presentations - šŸ”§ **Zero Configuration**: Works out of the box with sensible defaults ## Installation No installation required! Use directly with npx: ```bash npx create-marp-slides my-presentation ``` ## Usage ### Create a new presentation ```bash # Create with project name npx create-marp-slides my-slides # Interactive mode (prompts for project name) npx create-marp-slides # Skip dependency installation npx create-marp-slides my-slides --skip-install ``` ### After creation 1. Navigate to your project directory: ```bash cd my-slides ``` 2. Install dependencies (if skipped): ```bash npm install ``` 3. Start development server: ```bash npm run dev ``` 4. Build for production: ```bash npm run build ``` ## Generated Project Structure ``` my-slides/ ā”œā”€ā”€ slides.md # Your presentation content ā”œā”€ā”€ package.json # Project configuration ā”œā”€ā”€ .gitignore # Git ignore rules └── .github/ └── workflows/ └── deploy.yml # GitHub Actions for auto-deployment ``` ## Development Commands - `npm run dev` - Start development server with live reload - `npm run build` - Build slides to static HTML - `npm run preview` - Preview built slides locally ## Deployment to GitHub Pages 1. Push your project to GitHub 2. Go to repository Settings > Pages 3. Set Source to "GitHub Actions" 4. Edit `slides.md` and push changes 5. Your slides will be automatically deployed! šŸŽ‰ ## Marp Syntax The generated `slides.md` includes examples of: - Slide separators (`---`) - Themes and styling - Math formulas (KaTeX) - Code highlighting - Images and media - Speaker notes Learn more about Marp syntax at [marp.app](https://marp.app/) ## Requirements - Node.js 16.0.0 or higher - npm or yarn ## Contributing Contributions are welcome! Please feel free to submit a Pull Request. ## License MIT License - see [LICENSE](LICENSE) file for details. ## Related - [Marp](https://marp.app/) - Markdown Presentation Ecosystem - [Marp CLI](https://github.com/marp-team/marp-cli) - CLI interface for Marp - [GitHub Pages](https://pages.github.com/) - Static site hosting