webignition/robots-txt-file
Parse and work with robots.txt files: convert raw content into a model, query directives per user-agent, check if a path is allowed, extract sitemap URLs, filter directives by type, and generate robots.txt strings programmatically.
robots.txt policies for search engine visibility, indexing controls, or blocking unwanted crawlers (e.g., scrapers, bots). Aligns with SEO roadmaps or compliance requirements (e.g., GDPR data requests).robots.txt logic (e.g., dynamic rules based on user segments, A/B testing) without reinventing parsing/validation from scratch, while mitigating risks of outdated dependencies.robots.txt management across dev/staging/prod, reducing misconfigurations (e.g., accidentally blocking search engines in staging).Disallow: /private/ for sensitive paths).robots.txt, reducing edge-case bugs (e.g., malformed syntax).robots.txt generation (e.g., toggling rules via admin panel or environment-specific configurations).robots.txt files (e.g., user-uploaded or third-party configurations) with modern PHP standards (PSR-12, phpstan).robots.txt syntax manually or wants to reduce technical debt in legacy systems.robots.txt is a critical feature.robots.txt file (use a simple text file or Laravel’s public/robots.txt).robots.txt support.spatie/robots-txt).For Executives:
"This updated package lets us programmatically control search engine crawlers and block unwanted bots with modern PHP standards (PSR-12, phpstan), reducing risks of syntax errors and technical debt. It’s a lightweight, MIT-licensed solution that replaces error-prone manual robots.txt management, saving development time while ensuring compliance with SEO and data protection policies. The PHP 7.2+ requirement aligns with our long-term stack modernization, and the improved robustness makes it a safer bet for production use—though we’ll need to monitor for future updates or consider forking if maintenance stalls."
For Engineering:
*"The 3.0 release of webignition/robots-txt-file now enforces PHP 7.2+, adopts PSR-12 coding standards, and integrates phpstan static analysis for better code quality. Key benefits:
robots.txt before deployment (e.g., catch Disallow: / typos or malformed rules).Disallow: /admin only in production) with cleaner, standardized code.spatie/robots-txt for newer features, but this package is a solid choice if you prioritize code quality and PHP 7.2+ compatibility."*How can I help you explore Laravel packages today?