alleyinteractive/mantle-framework
Mantle is a Laravel-inspired framework for WordPress that brings Eloquent models, routing, service providers, and Blade-like views to plugin and theme development, helping teams build large-scale WordPress applications with familiar, modern PHP patterns.
Architecture fit
Mantle is Alley's Laravel-components-for-WordPress framework, and this release is confined to its asset pipeline layer — the wp-asset-manager integration that backs Mantle's script/style registration API. The architectural fit is therefore unchanged: this is a dependency-alignment patch on the maintained 1.x line, not a re-architecture. The notable shift is that Mantle now acts as a conduit for a downstream major version (wp-asset-manager 2.0), which means Mantle's own stability guarantees are partially coupled to a package it does not control.
Integration feasibility
Effort is low at the Composer level and moderate at the verification level. The constraint widening to ^1.4.0 || ^2.0 means any project that pulls wp-asset-manager only transitively through Mantle will silently land on 2.x at the next composer update. Feasibility hinges on one audit task: enumerate every asset registration using defer, async-defer, or a script that calls both async() and defer(), and confirm the resulting load semantics are acceptable.
Technical risk — rated Medium
composer.json is required to receive a new major of a third-party plugin. Standard lockfile discipline protects existing builds, but composer update in CI or on a maintenance branch is enough to cross the boundary.defer loads as async on 2.x. On front-end this can manifest as render-order or cascade differences that are hard to attribute back to a Composer update._doing_it_wrong() notices. These are developer-facing correctness signals. In WordPress test harnesses that promote notices to failures, they can break CI independent of any user-visible change.Load_Method::ASYNC_DEFER. Not a break in 1.x — Mantle passes the constant through on wp-asset-manager 1.x and coerces to async on 2.x — but it is a hard removal scheduled for Mantle 2.0. Any code referencing the constant (including the async() + defer() combination path) is now on a clock.Key questions
_doing_it_wrong() notices fire only with WP_DEBUG enabled, or unconditionally? This determines whether they are a production concern or a development-only signal.ASYNC_DEFER is used, or is the signal only the downstream _doing_it_wrong()?wp-asset-manager versus WordPress core's wp_enqueue_* — i.e. what is the actual blast radius of the 1.x/2.x split?wp-asset-manager independently, and could those constraints conflict with Mantle's new range?Stack fit
Unchanged for the standard Mantle profile: WordPress + Composer + a Laravel-style application structure. The new consideration is that wp-asset-manager must now be reasoned about as a first-class member of the dependency graph rather than an implementation detail. Teams using Bedrock or a comparable Composer-driven WordPress layout already have the tooling to express that constraint explicitly.
Migration path
Two viable paths, and the choice should be made deliberately rather than by default:
"alleyinteractive/wp-asset-manager": "^1.4" constraint to the root composer.json while on Mantle 1.22.x. This converts an implicit transitive decision into an explicit, auditable one and buys time to complete the load-method audit. It does not block the Mantle upgrade.defer/async-defer.Either way, the migration is reversible at the Composer level; the risk is front-end regression, not data or schema.
Compatibility
ASYNC_DEFER remains functional on 1.x and is coerced on 2.x, so application code compiles in both configurations; only behavior differs.HTML_Helpers::convertToHtmlEntities() is a static-analysis correctness change and carries no runtime compatibility implication, though teams running PHPStan at a pinned baseline may see their baseline entry become stale.Sequencing
defer, async-defer, and any script calling both async() and defer().wp-asset-manager constraint at the root so the version is a decision, not an accident.WP_DEBUG enabled to surface _doing_it_wrong() output.ASYNC_DEFER call sites ahead of Mantle 2.0.Maintenance
Ongoing maintenance load is low but concentrated: the work is a one-time asset audit plus a standing obligation to eliminate ASYNC_DEFER usage before Mantle 2.0. Teams that skip the audit inherit an open-ended debugging cost, because defer/async regressions present as visual or performance symptoms rather than errors. Owning an explicit wp-asset-manager constraint is the single highest-leverage maintenance action and costs one line.
Support
Support surface is essentially unchanged — no new APIs to learn, no new configuration. The support burden shifts toward diagnosis: "why did our stylesheet load order change after a routine dependency update" is now a supported question, and the answer requires someone who understands both Mantle's asset abstraction and wp-asset-manager's load methods. Worth documenting internally as a known-issue playbook.
Scaling
No scaling implications — this is a client-side asset loading concern, not a runtime or throughput one. The one adjacent consideration: async versus defer has measurably different effects on Core Web Vitals and paint timing, so on high-traffic properties the behavior change should be validated against real-user performance data rather than assumed neutral.
Failure modes
composer update — the dominant failure mode; manifests as a front-end change with no obvious code-level cause.defer → async changes cascade/ordering guarantees; can produce flashes of unstyled content or override regressions._doing_it_wrong() — test harnesses that promote notices to failures will go red on upgrade, arguably the good outcome since it surfaces the issue early.WP_DEBUG, expect log noise and potential customer-visible output in misconfigured environments.Ramp-up
Low. A developer familiar with WordPress enqueueing and Composer needs well under a day to understand the change; the substantive effort is the asset inventory, which scales with the size of the theme/plugin asset surface. The ASYNC_DEFER deprecation is trivially understood but easy to forget — assign it an owner and a ticket against the Mantle 2.0 milestone rather than leaving it as tribal knowledge.
How can I help you explore Laravel packages today?