-
Notifications
You must be signed in to change notification settings - Fork 0
FAQ and Troubleshooting
Practical answers to the most common StrataWP questions, with exact commands you can copy and paste.
This page is organized by topic. Use your browser's find (Ctrl/Cmd + F) to jump to a symptom. For deeper how-tos, see Installation & Quick Start, the CLI Reference, and Deployment.
Tip Before troubleshooting, confirm your environment meets the prerequisites: Node.js 18+ (engines require
node >=18.18), pnpm 8+ (or npm), PHP 8.1+, and WordPress 6.7+. A quick version check (below) resolves a surprising number of issues.
Run these first — many problems trace back to a version mismatch or a stale install.
node --version # Should be 18 or higher
pnpm --version # Should be 8 or higher
php --version # Should be 8.1 or higher
wp --version # WordPress CLI (if installed)
stratawp --version # StrataWP CLINote If
stratawp --versionorstratawp --helperrors with "command not found," the CLI isn't on your PATH. Run commands through your theme's local install instead:npx stratawp <command>. Allstratawpcommands work vianpxinside a theme created withcreate-stratawp.
StrataWP is a modern WordPress theme framework built with TypeScript, Vite, and Block Theme (FSE) architecture. It ships a CLI for scaffolding, a Vite plugin with HMR and block auto-registration, three example themes (Basic, Advanced, Store), a component explorer, headless utilities, and a full deployment/sync/rollback toolchain. See Home and Core Concepts for an overview.
No. Keep your StrataWP project in a separate development directory (for example ~/Projects/) and connect it to WordPress with a symlink. create-stratawp does this for you automatically when it detects your local WordPress site. See Installation & Quick Start.
pnpm is recommended (the repo is pinned to pnpm@8.12.1), but npm works. To install pnpm:
npm install -g pnpmThe Vite dev server runs at http://localhost:3000, but you browse your site at your local WordPress URL (for example http://localhost:8888 or your Local by Flywheel URL). HMR is injected into the WordPress page — you don't visit port 3000 directly for normal theme development.
Symptom: unknown command 'deploy' (or any newly added command), or a feature documented here is missing from stratawp --help.
Cause: Your globally installed stratawp points at an older build. Pulling new code does not rebuild or reinstall the global binary.
Fix — rebuild and reinstall the CLI from the repo:
# From the StrataWP repository root
cd packages/cli
# Build the CLI
pnpm build
# Install globally (updates the stratawp command)
npm install -g .
# Verify the update
stratawp --helpYou should now see the new command listed in the help output.
Tip To update the published
@stratawp/*packages inside a theme (rather than the dev CLI), usestratawp update(interactive),stratawp update --check(check only), orstratawp update --force(apply all without prompts).
Either install the CLI globally (see above) or prefix commands with npx inside your theme directory:
npx stratawp block:new hero --category=designSymptom: Error: Port 3000 is already in use
Fix — start the dev server on another port:
pnpm dev --port 3001Symptom: You save a file but the browser doesn't refresh or restyle.
Fix — work through these in order:
- Confirm the dev server is actually running and you've left its terminal open:
pnpm dev
- Hard-refresh the browser to clear cached assets: Cmd/Ctrl + Shift + R.
- Check the browser console for errors (a JS/TS error can halt HMR).
- Restart the dev server (stop with Ctrl + C, then
pnpm devagain).
Note StrataWP HMR behaves differently per file type: CSS/SCSS updates instantly with no reload, TypeScript/JavaScript triggers a fast rebuild and reload, and PHP/
theme.jsonchanges trigger an automatic page refresh (these paths are watched by the Vite plugin). If only PHP changes seem "slow," that's expected — they refresh the page rather than hot-swap.
Symptom: CSS changes don't appear on the frontend.
Fix:
- Check your SCSS for syntax errors (a failed compile keeps the old CSS).
- Confirm the build output exists — the
dist/directory should be present. - Clear any WordPress caching plugin's cache.
- Hard-refresh the browser (Cmd/Ctrl + Shift + R).
Symptom: A block you created doesn't appear in the editor inserter.
StrataWP's Vite plugin auto-discovers blocks by scanning src/blocks/*/block.json and generating the PHP registration. If a block isn't showing up:
- Confirm the block lives under
src/blocks/<name>/and has a validblock.jsonwith a uniquename(for examplemy-theme/hero). - Confirm the dev server (or a production build) has run so the manifest and generated registration are up to date:
pnpm dev # during development # or pnpm build # for production
- Check the browser console and the dev-server terminal for build errors in the block's
edit.tsx/render.php. - If you just added the block while the server was running, restart
pnpm devso the newblock.jsonis picked up by discovery.
Tip Generate blocks with the CLI to get a correct file layout every time:
stratawp block:new hero --category=designThis scaffolds
block.json,edit.tsx,render.php, andstyle.cssundersrc/blocks/hero/. StrataWP blocks are dynamic (server-rendered viarender.php) — there is no staticsavecomponent.
Symptom: The theme is missing from Appearance → Themes.
Fix:
- Verify the symlink points at your theme directory:
You should see your theme name linking back to your project folder.
ls -la /path/to/wordpress/wp-content/themes/
- Ensure
style.csshas a valid theme header (at minimum aTheme Name:). - Check file permissions on the project directory.
If create-stratawp didn't auto-link (or you skipped it), create the symlink yourself. Run this from your theme directory:
# Confirm where you are first
pwd # e.g. /Users/yourname/Projects/my-theme
# Link into WordPress (adjust the WordPress path for your setup)
ln -s "$(pwd)" ~/Local\ Sites/mysite/app/public/wp-content/themes/my-themeIf you hit a permission error creating the link:
sudo ln -s "$(pwd)" /path/to/wordpress/wp-content/themes/my-themeSee Installation & Quick Start for full setup, including how the CLI scans Local by Flywheel and MAMP sites.
Symptom: Build failed with errors
Fix — clear caches and dependencies, then reinstall and rebuild:
rm -rf node_modules dist .vite
pnpm install
pnpm buildFix — reinstall dependencies and re-run the type checker:
rm -rf node_modules
pnpm install
pnpm type-checkAuto-fix what ESLint can:
pnpm lint --fixFor full deployment setup, see Deployment and the canonical guide at docs/deployment/getting-started.md.
Fix:
- Double-check
host,port,username, and credentials. - Confirm SFTP/SSH is enabled on your server.
- Use the correct port —
21for FTP,22for SFTP/SSH. - Test the connection without deploying:
stratawp deploy:test production
Tip Store credentials in a
.envfile and reference them in your deploy config with${VAR_NAME}syntax (for example"password": "${STRATAWP_DEPLOY_PROD_PASSWORD}"). Add.envto.gitignore.
Provide the passphrase via an environment variable (you'll otherwise be prompted):
STRATAWP_SSH_PASSPHRASE="your-passphrase" stratawp sync:db:pull productionIn a deploy config, reference it the same way: "passphrase": "${STRATAWP_SSH_PASSPHRASE}".
- Confirm your FTP/SSH user has write permissions to the remote path.
- Verify the remote path actually exists.
- Some hosts require specific directory permissions — check with your provider.
Cause: StrataWP tracks deployments with a manifest at ~/.stratawp/deployments/{environment}.json. If it drifts out of sync with the server, changed files can be skipped.
Fix — bypass the manifest and upload everything:
stratawp deploy production --freshAlternative — delete the manifest so the next deploy rebuilds it:
rm ~/.stratawp/deployments/production.jsonstratawp deploy production --dry-run # show what would change
stratawp deploy production --verbose # add debug outputSymptom: Syntax or fatal errors referencing typed properties, union types, or match expressions; the theme fails to load.
Cause: StrataWP's PHP core requires PHP 8.1 or higher.
Fix:
- Check the PHP version your WordPress site actually uses (not just your shell):
In Local by Flywheel, MAMP, or your host's panel, confirm the site's PHP version is 8.1+ — it can differ from your terminal's
php --version
php. - Upgrade the site's PHP version to 8.1 or higher, then reload.
StrataWP targets WordPress 6.7+. Older versions may lack the Block Theme (FSE) APIs the framework relies on. Update WordPress core, then re-activate the theme.
If none of the above resolves your problem:
- Re-check the Quick diagnostics versions above.
- Search existing issues — your problem may already have an answer: GitHub Issues.
- Browse community questions in GitHub Discussions.
- Still stuck? Open a new issue: github.com/JonImmsWordpressDev/strataWP/issues.
When you open an issue, include:
| Detail | How to get it |
|---|---|
| Node.js version | node --version |
| pnpm version | pnpm --version |
| PHP version | php --version |
| WordPress version | Admin dashboard or wp --version
|
| Full error message | Copy the complete stack trace |
| Steps to reproduce | What you ran, in order |
| What you've already tried | List the fixes you attempted |
Tip Reproducing the problem against a fresh
npx create-stratawptheme helps pinpoint whether the issue is in your code or the framework — and makes your issue much faster to triage.
Related pages: Installation & Quick Start · CLI Reference · Blocks, Patterns & Design Systems · Deployment · Environment Sync & Rollback
StrataWP v2.0.0 · GPL-3.0-or-later · Built by Jon Imms Repository · README
Start here
Building themes
Shipping
Extending & contributing
Help