- What is trendyminds/janitor used for?
- Janitor is a Statamic addon for Laravel applications that simplifies block organization in the control panel. It helps developers manage and structure content blocks more efficiently. The package is installed via Composer and integrates with Statamic's addon system. Release 1.4.2 also requires running npm run build and updating the search index before use.
- How do I install trendyminds/janitor?
- Install it with Composer using composer require trendyminds/janitor. After installation, follow Statamic addon registration steps and publish any assets if needed. For version 1.4.2, also run npm run build and update the search index as part of deployment. Check the README for exact commands and environment requirements.
- Does Janitor support Laravel 10 and 11?
- Janitor is a Statamic addon, so its Laravel version support is tied to the Statamic version you run. Verify the package's composer.json constraints for both Statamic and Laravel before upgrading. The 1.4.2 release is a patch and should be Composer-compatible, but the npm and search-index prerequisites are not covered by Composer constraints. Test in a staging environment that matches production.
- Why does Janitor 1.4.2 require npm run build?
- The 1.4.2 release note indicates the package depends on compiled frontend assets, so npm run build must run before the package is used. This is an operational precondition rather than an API change. If your Laravel app already has a Node-based asset build stage, add npm ci && npm run build to CI/CD. PHP-only pipelines will need to introduce Node tooling.
- What search index update is needed for Janitor 1.4.2?
- The release requires updating the search index before running the package, which suggests Janitor relies on synchronized search data. Confirm which search backend is affected and whether the update is mandatory for local, CI, and production environments. Treat the index update as a repeatable deployment task and test it with production-like data. Check whether the update is idempotent and safe to rerun, and whether it requires downtime or a queue worker.
- Is Janitor a cleanup package for pruning stale records?
- The repository describes Janitor as a Statamic addon to simplify block organization, not a general cleanup package for pruning records or temporary files. Some descriptions may conflate it with maintenance tools, so verify the package's actual features in the README. For 1.4.2, focus on the block-organization use case plus the npm build and search-index deployment steps. If you need record pruning or temporary-file cleanup, look for a dedicated Laravel maintenance package instead.
- Can I use Janitor in a PHP-only deployment pipeline?
- It is a poor fit for PHP-only pipelines because 1.4.2 requires npm run build and a search index update. You would need to add a Node build stage and an index synchronization process to your deployment. Teams that already use npm and a search backend will find integration more feasible. If adding Node tooling is not acceptable, consider an alternative addon or defer upgrading.
- What are the production risks of upgrading to Janitor 1.4.2?
- The technical risk is medium: the patch version suggests no intentional breaking API change, but the release adds deployment-critical steps. Missing npm run build can cause missing assets or broken UI, and a skipped index update can cause stale search results or runtime errors. CI environments without Node will fail. Add runbooks and rollback steps, and validate search and asset loading after deployment.
- How should I test and sequence the Janitor 1.4.2 deployment?
- First confirm the package requirements and which search backend is affected. Update CI/CD to run npm ci && npm run build, then add the search-index update as a repeatable deployment task. Test in staging with production-like index data before deploying code and index changes in a controlled order. Finally, validate search and asset loading post-deploy.
- What ongoing maintenance does Janitor 1.4.2 add?
- It adds Node toolchain and search-index maintenance to the package lifecycle. Teams must track npm dependencies, build reproducibility, and index schema or version changes. Support burden may increase because failures can come from missing frontend build artifacts or stale indexes, not only PHP errors. Clear runbooks and rollback steps are needed, and you should confirm whether index updates are incremental or full rebuilds.