van-ons/laraberg
Laraberg integrates the WordPress Gutenberg block editor into Laravel, giving your apps a modern WYSIWYG editor with blocks, media uploads, and easy content rendering.
Architecture fit
Laraberg is a Laravel service provider that publishes compiled Gutenberg (WordPress block editor) assets and exposes a thin JS/PHP API: mount the editor onto a form field, serialize content, render it back server-side. For a classic Blade-based Laravel CMS with a <textarea>-driven content form, the fit is genuinely good — it is a drop-in, not an integration project. Fit degrades quickly outside that shape: Inertia/Vue/React SPAs will fight the global script-tag bootstrap, and API-only/headless products gain nothing.
The critical architectural caveat is that Gutenberg is not a standalone editor — it is a UI over wp.data/core-data stores and a wp-json REST API. Laraberg shims a subset of that runtime. Blocks depending on post entities, the media library, reusable blocks/patterns, Query Loop, or Site Editor concepts will fail, error, or degrade. We inherit the block surface without the platform, so editor expectations must be scoped up front.
Integration feasibility Low effort to a working demo (config + asset publish + one Blade directive), moderate effort to production-grade. The real work is not mounting the editor; it is (a) a trustworthy server-side renderer, (b) HTML sanitization of user-authored block markup, (c) media upload endpoints/storage, and (d) a content model that survives round-trips (persist both rendered HTML and the block JSON).
Technical risk
Key questions
Stack fit
Best: Laravel 9–10, Blade/Livewire admin, server-rendered public pages. Acceptable: Livewire with a mounted <div> and event dispatch. Poor: Inertia + Vue/React, headless APIs, mobile clients.
Migration path
vendor:publish config and assets; add the package's CSS/JS includes to admin layouts only.content_blocks (JSON, editor source of truth) alongside existing content (rendered HTML, cached). Do not overwrite the legacy column until the renderer is validated.Compatibility
Pin three things explicitly: the package version, the bundled Gutenberg build, and PHP/Laravel minors. The shipped assets are pre-compiled and loaded via script tags — expect collisions with Vite/Mix global CSS (wp-block-library styles leak broadly) and with CSP headers. Scope Gutenberg CSS to the editor container and audit the public-facing render stylesheet separately. Media handling is ours: define an upload endpoint, disk (S3), MIME/size validation, and stable URLs, since the package does not own media lifecycle.
Sequencing
Decision gate: if the spike surfaces REST-dependent block failures, CSP/asset conflicts, or a negative legal opinion, fall back to TipTap/Editor.js/Filament RichEditor — but keep the content_blocks JSON + content HTML storage contract so the switch stays cheap.
Maintenance Treat this as adopting an unmaintained dependency. Realistic plan: fork within 12 months. Budget ~0.2–0.5 FTE for the fork, the Gutenberg asset rebuild (Node/yarn, non-trivial), and periodic upstream rebases — or explicitly accept a frozen block set and document it as a product constraint. The stale release cadence means we inherit the upgrade treadmill WordPress itself carries, without WordPress's release engineering.
Support No vendor, no SLA. GitHub issues from a single maintainer, GPL community norms. We need an internal runbook covering editor bootstrap failures, block validation errors, and asset rebuild steps — plus a named owner.
Scaling Editor bundle is heavy (hundreds of KB of JS/CSS); acceptable on admin screens, unacceptable on public pages — public pages must consume pre-rendered HTML, never the editor stack. Server-side rendering is CPU-bound per request: render on save, persist HTML, invalidate on edit. Media uploads hit our own storage; size/validate/thumbnail at ingest to avoid unbounded originals.
Failure modes
Ramp-up Content editors with WordPress exposure need near-zero training — this is the package's core business value and should be weighed explicitly against its carrying cost. Engineers need ~1–2 weeks to internalize asset pipeline, block serialization, and the renderer. QA needs a block regression fixture set (one saved sample per supported block) wired into CI before the first upgrade.
Bottom line: viable for an internal, Blade-based Laravel CMS where WordPress-editor familiarity is a genuine requirement and a fork is budgeted. Not viable as a long-term dependency for a distributed commercial product without a positive GPL opinion and a named owner.
How can I help you explore Laravel packages today?