WP Manifestindependent plugin directory
manifest / themes / my-snow-monkey-boilerplate

My Snow Monkey

Development boilerplate for the My Snow Monkey WordPress plugin.

★ 1stars

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/foolish-pine/my-snow-monkey-boilerplate/archive/refs/heads/main.zip
Updates itself. It ships its own updater (Update URI header), so new versions appear under Dashboard → Updates.

A development boilerplate based on the official My Snow Monkey plugin template. My Snow Monkey is an official plugin provided by the Snow Monkey theme team for customizing the Snow Monkey theme. This boilerplate provides a structured development environment with modern tooling for CSS processing, code linting, and automated workflows.

Features

  • Modern CSS Pipeline: PostCSS with imports, nesting, and automatic vendor prefixing
  • Code Quality: Automated linting and formatting for PHP and CSS
  • Local Development: WordPress local environment with browser-sync live reload
  • Git Hooks: Pre-commit hooks for automatic code formatting and linting
  • Dependency Management: Automated dependency updates with Renovate

Requirements

Installation

  1. Clone this repository:
git clone https://github.com/foolish-pine/my-snow-monkey-boilerplate
cd my-snow-monkey-boilerplate
  1. Install Node.js dependencies and set up Git hooks:
npm install
npx lefthook install
  1. Install PHP dependencies:
composer install

Development Setup

Starting Local WordPress Environment

This project uses @wordpress/env for local development:

# Start WordPress environment (accessible at http://localhost:8888)
npm run wp-env start

# Stop the environment
npm run wp-env stop

The plugin will be automatically mapped to wp-content/plugins/my-snow-monkey in the WordPress installation.

Installing and Activating Snow Monkey Theme

  1. Access WordPress admin at http://localhost:8888/wp-admin (default credentials: admin/password)
  2. Install and activate the Snow Monkey theme
  3. Activate the "My Snow Monkey" plugin from the Plugins page

Note: This plugin only works when the Snow Monkey theme is active.

Development Workflow

Start the development server with file watching and live reload:

npm run watch

This will:

  • Watch CSS files and rebuild on changes
  • Start browser-sync proxy server at http://localhost:3000 (proxying http://localhost:8888)
  • Automatically reload the browser when files change

Available Scripts

Building

# Build all assets (CSS)
npm run build

# Build CSS only
npm run build:styles

The build process compiles CSS files from src/styles/ through PostCSS (with imports, nesting, vendor prefixing, and minification) and outputs the result to dist/style.css, which is automatically loaded in WordPress.

Linting

# Run all linters
npm run lint

# Lint CSS files
npm run lint:stylelint

# Check code formatting
npm run lint:prettier

# Lint PHP files
composer lint

Fixing

# Auto-fix all issues
npm run fix

# Fix CSS issues
npm run fix:stylelint

# Fix code formatting
npm run fix:prettier

# Fix PHP issues
composer fix

Customization

Adding CSS Styles

  1. Place your CSS files in the src/styles/ directory
  2. Import them in src/styles/style.css:
@import url(your-custom-file.css);
  1. Run npm run build or npm run watch to compile

Your compiled CSS will be output to dist/style.css and automatically loaded in WordPress.

This project is optimized for Visual Studio Code (or compatible forks like Cursor). When you open the project in VS Code, you will be prompted to install the recommended extensions.

Recommended Extensions

The workspace settings are pre-configured to:

  • Format code automatically on save
  • Use WordPress coding standards for PHP
  • Lint and fix CSS with Stylelint

Code Quality

This project follows:

  • WordPress Coding Standards for PHP
  • WordPress Stylelint Configuration for CSS
  • WordPress Prettier Configuration for formatting

License

MIT