Directory Structure
PorterWP keeps all theme‑specific code and assets in a single /porter
directory.
my-theme
├── porter
│ ├── blocks/ # ACF blocks (one folder per block)
│ ├── inc/ # Plain‑PHP helpers loaded automatically
│ ├── config/ # JSON config files (see below)
│ ├── assets/ # Theme‑level JS/SCSS processed by gulp
│ └── blocks/make.sh # Scaffold script for new blocks
└── functions.php
Key Config Files
porter.json
Global options, asset enqueues & premium feature flags
posttypes.json
Registers Custom Post Types
taxonomies.json
Registers Custom Taxonomies & their relationships
blocks.json
Single hub for block registration: links ACF block folders, adds extra block styles, and registers block patterns
acf.json
ACF Option pages (Key Pages, theme colours, etc.)
Details: See the Configuration Files Index
The inc/
autoloader
inc/
autoloaderAny PHP file placed in porter/inc
(or nested sub‑folders) is required automatically on after_setup_theme
:
Folders
first/
andtraits/
are loaded before everything else.Exclude a folder/file with
add_filter( 'porter_wp_inc_filepath_exclusions', … )
.
Returned paths are cached in the porter_inc_files*
options when the site is in a production
environment. Cache invalidates when you bump the version
key inside porter/config/porter.json
.
Last updated