magento2-backend-toolkit
Installation
SKILL.md
Magento 2 Backend Toolkit
General Rules
- All generated code MUST follow PSR-12 coding standard
- All PHP files MUST have
declare(strict_types=1); - Use strict type hints on all method parameters and return types
- Namespace follows:
Vendor\Module\Pathconvention - XML files must include proper XSD schema references
- Default Vendor name: ask user, suggest
Sampleif not specified - NEVER use ObjectManager directly — only use DI
- NEVER use constructor property promotion (
private readonlyin constructor params) — always declare properties explicitly above the constructor and assign them in the constructor body - ALL class properties MUST have a
@varPHPDoc block with the fully-qualified class name - ALL constructors MUST have a
@paramPHPDoc block with fully-qualified class names for each parameter - ALL public and protected methods MUST have a PHPDoc block with a short description and
@param/@returntags - Always create
composer.jsonwith new modules
Security Rules (Required)
Related skills
More from tuanhaviet22/magento-skills
magento2-db-performance
>
4magento2-custom-logger
>
4magento2-db-sql-csv
Magento 2 best practices for database queries and CSV exports. Use when writing SQL queries, fetching data from DB, or exporting data to CSV files. Triggers on tasks involving raw SQL, SELECT queries, JOIN operations, CSV generation, or file export adapters. DO NOT use for frontend, caching, or search topics.
4magento2-warden
>
3