Packaging & Distribution
Pre-Release Checklist
| Item | Status |
|---|---|
| Valid style.css header | ☐ |
| Complete theme.json | ☐ |
| All templates working | ☐ |
| Patterns registered | ☐ |
| Translations ready | ☐ |
| Screenshot (1200x900) | ☐ |
| readme.txt complete | ☐ |
| Theme tested | ☐ |
| Accessibility checked | ☐ |
Required Files
my-theme/
├── style.css # Theme metadata
├── theme.json # Configuration
├── screenshot.png # 1200x900 preview
├── readme.txt # For WordPress.org
├── functions.php # PHP functionality
├── templates/
│ ├── index.html # Required fallback
│ ├── single.html
│ ├── page.html
│ ├── archive.html
│ └── 404.html
├── parts/
│ ├── header.html
│ └── footer.html
├── patterns/
│ └── *.php
├── styles/
│ └── *.json
└── assets/
├── css/
├── js/
└── images/readme.txt Format
=== My Block Theme ===
Contributors: yourusername
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
== Description ==
A brief description of your theme. Explain what makes it special and who it's for.
== Installation ==
1. Upload the theme folder to `/wp-content/themes/`
2. Activate via Appearance > Themes
3. Start customizing in the Site Editor
== Changelog ==
= 1.0.0 =
* Initial release
== Credits ==
* Font: Inter by Rasmus Andersson (OFL License)
* Images: Unsplash (Unsplash License)Translation Ready
Using Translation Functions
// In PHP
__( 'Text', 'my-theme' )
_e( 'Text', 'my-theme' )
esc_html__( 'Text', 'my-theme' )
esc_attr__( 'Text', 'my-theme' )
// Pluralization
sprintf(
_n( '%d item', '%d items', $count, 'my-theme' ),
$count
)Making Patterns Translatable
<!-- wp:heading {"level":1} -->
<h1></h1>
<!-- /wp:heading -->
<!-- wp:paragraph -->
<p></p>
<!-- /wp:paragraph -->Generate POT File
# Using WP-CLI
wp i18n make-pot . languages/my-theme.pot --domain=my-theme
# Set text domain
wp i18n update-po languages/my-theme.potTheme Check Plugin
Install and run Theme Check before submission:
1. Install Theme Check plugin
2. Go to Appearance > Theme Check
3. Select your theme
4. Check required items passCommon issues:
- Missing text domain
- Deprecated functions
- Incorrect escaping
- Missing license headers
Accessibility Testing
# Test with axe-core
npm install -g @axe-core/cli
axe https://yoursite.test/
# Or use WAVE browser extension
# Or Pa11y
npx pa11y https://yoursite.test/Key accessibility requirements:
- Keyboard navigation
- Skip links
- Proper heading hierarchy
- Color contrast (4.5:1 minimum)
- Focus indicators
- Alt text for images
Creating the ZIP Package
# Navigate to themes directory
cd wp-content/themes
# Create clean zip
zip -r my-theme.zip my-theme
-x "*.git*"
-x "*.DS_Store"
-x "*node_modules*"
-x "*.map"
-x "package*.json"
# Or with rsync first
rsync -av --exclude-from='.distignore' my-theme/ dist/my-theme/
cd dist && zip -r my-theme.zip my-theme.distignore File
.git
.github
.gitignore
.editorconfig
node_modules
package.json
package-lock.json
*.map
*.md
!readme.md
.DS_Store
composer.json
composer.lock
phpcs.xml
tests
.distignoreSubmitting to WordPress.org
- Create account at wordpress.org
- Go to: https://wordpress.org/themes/upload/
- Upload ZIP file
- Wait for review (can take weeks)
- Address any reviewer feedback
Review Requirements
| Requirement | Description |
|---|---|
| GPL License | Code must be GPL-compatible |
| No obfuscated code | All code readable |
| No phone-home | No external requests except updates |
| No upselling | Can link to pro version, not push |
| Proper escaping | All output escaped |
| Working features | All advertised features work |
Commercial Distribution
For selling themes:
- Licensing - Include license verification
- Updates - Provide update mechanism
- Documentation - Comprehensive docs
- Support - Support system
License Header for Commercial
/**
* @license Commercial License
* @link https://yoursite.com/license
*
* This theme is sold under a commercial license.
* See LICENSE.txt for the complete license agreement.
*/Version Control
# Tag releases
git tag -a v1.0.0 -m "Release version 1.0.0"
git push origin v1.0.0
# Changelog
git log --oneline v0.9.0..v1.0.0Congratulations!
You've completed the Full Site Editing Theme Development tutorial!
What You've Learned
- ✅ Block theme fundamentals
- ✅ theme.json configuration
- ✅ Building block templates
- ✅ Creating template parts
- ✅ Designing block patterns
- ✅ Global style variations
- ✅ Adding PHP functionality
- ✅ Packaging for distribution
Resources
🎯 Tutorial Complete! You're now ready to build professional FSE block themes.