Skip to content

Frontend Optimiser

This page is generated from package source documentation in the Capell packages repository and the checked-in manifest. Source documentation is not distribution status. Before running a Composer command, verify that the exact package and compatible 1.x release are available through public Packagist or the authenticated marketplace account.

FieldValue
Composer packagecapell-app/frontend-optimizer
Package slugfrontend-optimizer
Product groupCapell Operations
Tierpaid
Bundleoperations
Runtime contextsadmin, console, frontend
Capell version^1.0
Catalogue roleextension
Release channelBeta
Docs sourcepackages/frontend-optimizer/docs
Manifestcapell.json

Visitors on any device see the top of each page drawn from a few styles already built into it. The full stylesheet, the file that sets how everything looks, downloads behind it. Without that, the browser holds the page back until the whole file has arrived.

The edit forms for a site, a layout or a page each get a Critical CSS tab, for the first-screen styles. It sets how pages are grouped when styles are built. A page without its own choice takes its layout’s, then its site’s. On any one page you can choose Disable above-the-fold CSS, and that page goes back to the ordinary stylesheet.

Building the styles needs Chromium, a browser engine, and Node, which runs JavaScript. Both must be on the server that runs your background jobs. The default queue must use the database, Redis, SQS or Beanstalkd, and Capell skips the work on any other. A developer installs Chromium once with a command the package provides. The first visit to a page gets the normal stylesheet while Chromium opens the page at three screen sizes, in light and dark, and saves the styles it finds. Later visits get those saved styles in the page itself.

  • Price and availability: Check current availability and price on the Capell Marketplace listing.
  • Licence: Check the licence terms on the Capell Marketplace listing.
  • Requires: PHP ^8.4, capell-app/admin ^1.0.66, capell-app/core ^1.0.79, capell-app/frontend ^1.0.79, lorisleiva/laravel-actions ^2.8, spatie/laravel-data ^4.5, spatie/laravel-package-tools ^1.14.1, symfony/process ^7.2|^8.0.
  • Install: composer require capell-app/frontend-optimizer.
  1. Install the package: composer require capell-app/frontend-optimizer.
  2. Open a host admin workflow that uses the package extension and verify Frontend Optimiser is available.

Actions separate scope resolution, profile persistence, asset rendering, critical CSS generation, and retention, while the full stylesheet remains blocking until a fresh artifact exists.

  • Configuration files: config/capell-frontend-optimizer.php.
  • Admin settings: Capell\FrontendOptimizer\Settings\FrontendOptimizerSettings.
  • Commands: php artisan capell:frontend-optimizer:generate-critical-css, php artisan capell:frontend-optimizer:pause-generation, php artisan capell:frontend-optimizer:prune-profiles, php artisan capell:frontend-optimizer:resume-generation, php artisan capell:frontend-optimizer:status.
  • Install the required Capell packages at the versions in composer.json: capell-app/admin ^1.0.66, capell-app/core ^1.0.79, capell-app/frontend ^1.0.79.
  • Run migrations before opening package resources or public routes.
  • Keep the host Laravel scheduler running so package-registered schedules can execute: capell:frontend-optimizer:prune-profiles (daily; manifest declared), capell:frontend-optimizer:status --repair --probe-storage (everyThirtyMinutes; manifest declared).
  • Keep public Blade and cached HTML free of authoring markers, model IDs, permissions, signed editor URLs, and lazy database queries.
  • Custom write integrations must preserve invalidation for frontend-optimizer cache tags.

Frontend Optimiser Critical CSS page settingsFrontend Optimiser Critical CSS page settings

Frontend Optimiser profile asset outputFrontend Optimiser profile asset output

  • Frontend Optimiser Critical CSS page settings (admin).
  • Frontend Optimiser profile asset output (frontend).
  • Illustrative Frontend Optimiser critical CSS output preview (frontend).
  • Frontend Optimiser settings (admin).
  • Required packages: capell-app/admin, capell-app/core, capell-app/frontend.
  • Admin navigation: no admin page or resource contribution is declared.
  • Admin/editor extensions: configurator: FrontendOptimizerConfiguratorContribution, schema-extender: FrontendOptimizerSchemaExtendersContribution.
  • Permissions: no package permission declarations or Shield gates detected; host access rules still apply.
  • Public routes: none declared.
  • Database changes: package migrations are declared.
  • Config: config/capell-frontend-optimizer.php.
  • Settings: Capell\FrontendOptimizer\Settings\FrontendOptimizerSettings.
  • Queues or schedules: scheduled commands capell:frontend-optimizer:prune-profiles (daily; manifest declared), capell:frontend-optimizer:status --repair --probe-storage (everyThirtyMinutes; manifest declared); queue jobs GenerateCriticalCssJob.
  • Cache tags: frontend-optimizer.
  • Commands: capell:frontend-optimizer:generate-critical-css, capell:frontend-optimizer:pause-generation, capell:frontend-optimizer:prune-profiles, capell:frontend-optimizer:resume-generation, capell:frontend-optimizer:status.
SymptomLikely causeCheckFix
Package health check reports a problemPackage configuration or runtime dependencies are not readyRun php artisan capell:frontend-optimizer:statusFollow the reported checks, then rerun the doctor command
Package surface is missing after installProvider or manifest is not loadedConfirm capell.json, package composer.json, and provider registrationReinstall the package, refresh Composer autoload, and clear host caches
Admin screen or command fails on missing tablePackage migrations have not runCheck the tables listed in Data ModelRun host migrations and rerun the focused package test
Background work does not runQueue worker or declared schedule is not activeCheck the jobs and scheduled commands listed in Technical ShapeStart the queue worker or host scheduler, then run the focused command or package test
Public output leaks unexpected stateRender data, cache variation, or authoring boundary has regressedCheck public Blade, cache tags, and public-output safety testsMove data loading out of Blade and rerun the package public-output tests

No manual steps between minor versions.

Read CHANGELOG.md before upgrading.