Bootstrap

aegis.php defines constants (DIR, FILE, VERSION, MIN_THEME_VERSION) and loads the plugin’s own PSR-4 autoloader, src/autoload.php. It does not use Composer at runtime. It then requires config/updater.php, which starts the plugin updater. This happens before the theme check, so updates still work without the Aegis theme.

Next, the plugin checks that the Aegis theme is active. Without it, bootstrap stops there and an admin notice is shown. If the theme is older than MIN_THEME_VERSION (1.0.0), the plugin still loads but shows a notice recommending an update.

With the theme active, the feature configs load in this order:

Copied!
Directory tree
config/coauthors.phpconfig/map.phpconfig/analytics.phpconfig/blocks.php / blocks-registrar.phpconfig/modal.phpconfig/injection.php (requires injection-integrations.php)config/hooks.phpconfig/snippets.phpconfig/visibility-presets.phpconfig/license.phpconfig/conditionals.php / conditionals-renderer.phpconfig/integrations.phpconfig/connectors.phpconfig/seo.phpconfig/admin.phpconfig/admin-shell.phpconfig/editor.phpconfig/performance.phpconfig/woocommerce.phpconfig/patterns.phpconfig/woocommerce-patterns.phpconfig/activation-redirect.php

config/license.php registers the free License (Get Pro) page on after_setup_theme. The page is skipped when Aegis Pro is installed, because Pro replaces it with its license screen on the same aegis-license slug.

aegis.php also loads the plugin text domain (aegis) from languages/ on init. Plugin UI strings ship in languages/aegis.pot. They are not merged into the theme POT. See Building Assets.

Namespace

Module Overview

ModuleResponsibility
Admin/Menu, Renderer, AdminTabs, UI (shared admin kit helpers), the updater (native WordPress updates from the aegis.zip package of the latest release; repository filterable with aegis_plugin_update_repository)
Analytics/Tracker, Connectors panel, Settings
Blocks/Registrar, AdminPage, SettingsController, VideoSchema, and Settings. Blocks\Settings owns the whole aegis_blocks option: every block feature toggle (theme blocks, plugin blocks, and core block extensions such as Query Loop) plus the Aegis → Performance keys (embed_facades, perf_*)
Conditionals/Evaluator, AdminPage, PostContentRenderer, SmartConditionsEvaluator, IntegrationsPanel (plugin extras on Aegis → Integrations). Posts and hook patterns share should_render_conditions(). User extras include status, role, capability (current_user_can on a normalized slug), specific users, and Pro user meta. Schedule extras parse naive datetimes with DateTimeImmutable in an IANA zone (or the site timezone); non-IANA saved zones fall back to the site timezone. Image Source extras are Pro (AegisPro\Query\ImageSource). Viewport/a11y classes go on the existing post-content root (Visibility::apply_classes()); hook patterns wrap (Visibility::wrap()).
Connectors/Connectors admin (BunnyCDN, Maps, Analytics panels)
General/General settings admin (data removal)
Hooks/Hook patterns admin (instance list)
VisibilityPresets/Visibility presets admin (library list; CRUD requires Pro)
Injection/LocationRegistry, Preview, IntegrationInjector (including Co-Authors Plus wrap of core/post-author and co-authors/block)
CoAuthors/Multi-author core/post-author* replace, optional Author Schema extra
Integrations/Registry, AdminPage, Settings, Notices, WPFusion (catalog pickers, list membership, CRM login, plugin detection), ACF (plugin detection and parent gating, including Secure Custom Fields), MetaBox (RWMB_Loader / rwmb_meta(), including AIO), CodeBlockPro (CBPRouter / kevinbatdorf/code-block-pro detection), SyntaxHighlighting (Syntax_Highlighting_Code_Block\PLUGIN_VERSION / boot()), AffiliateWP (Affiliate_WP / affiliate_wp() / AFFILIATEWP_VERSION), EasyDigitalDownloads (Easy_Digital_Downloads / EDD() / EDD_VERSION), FluentBooking (FluentBooking.php helper: FLUENT_BOOKING_VERSION / FluentBooking\App\App, plus is_enabled()), FluentForms (FluentForms.php helper: FLUENTFORM / FLUENTFORM_VERSION / FluentForm\App\Modules\Form\Form, plus is_enabled()), GravityForms (GravityForms.php helper: GFForms / GFAPI / GF_MIN_WP_VERSION / gravity_form(), plus is_enabled()), NinjaForms (NinjaForms.php helper: Ninja_Forms / NF_PLUGIN_VERSION / NF_VERSION, plus is_enabled()), LearnDash (LearnDash.php helper: LEARNDASH_VERSION / SFWD_LMS / LEARNDASH_LMS_PLUGIN_DIR / learndash_init(), plus is_enabled()), WooCommerce (WooCommerce.php helper: WooCommerce / WC() / WC_VERSION, plus is_enabled()), WooCommerce\MultiStepCheckout (assets on the multi-step template when the integration is on)
Map/Map block, Google Maps connectors panel, Static Maps style encoding
Modal/Modal block, instance scanner, Modals admin
Seo/SEO Manager and plugin adapters
Settings/Repository, Controller (AJAX export/import), Migration
Snippets/Manager, Storage, Loader, Executors
Patterns/CommercePatternRegistrar — gated WooCommerce and wishlist patterns
Performance/FrontendOptimizations, Performance admin page
License/AdminPage: free License / Get Pro screen (aegis-license), registered only when Aegis Pro is inactive
Utilities/UserAgent: device and browser matching for conditional logic rules

CommercePatternRegistrar

See Plugin Patterns — CommercePatternRegistrar for dependency checks, init priority, and slug registration.

Block Registration Model

LayerRegisters
ThemeNone once the removal release ships. Until then the theme registers the six blocks below only when the plugin has not.
Pluginaegis/countdown, slider, slide, toggle, toggle-content, related-posts (Blocks\ThemeBlocksRegistrar), aegis/map, aegis/modal (+ admin, core/video editor extensions)
Proaegis/tabs, tab, image-compare (src/Blocks/image-compare); attribute extensions on theme blocks, plugin blocks, core/video, and core/query

Video is core/video, not aegis/video.

Framework Dependency

The plugin reads and writes settings via Settings\Repository. The Aegis framework (vendor/aegis/framework in the theme) reads these settings for:

Relationship to Theme and Pro

LayerRole
ThemeRegisters six custom blocks, FSE assets, framework bootstrap, core/video enhancements
Free pluginSettings, admin, map/modal, snippets, conditionals, analytics, core/video editor scripts, gated commerce patterns
ProHook pattern CPT, video stack on core/video, query pro on core/query, Pro-only blocks, block extensions, license

Next Steps