I would like to propose the addition of a new feature in Eclipse PDT that allows developers to include the declare(strict_types = 1); statement in generated PHP classes, interfaces, and traits through respective wizards.
Details:
Checkbox Addition:
Introduce a new checkbox in the NewPHPClassWizard and NewPHPInterfaceWizard UIs, labeled "Add Strict Types Declaration." This checkbox will give developers the option to include the declare(strict_types = 1); statement in the generated PHP code.
Code Generation Logic:
Modify the code generation logic in the wizards to include the declare(strict_types = 1); statement when the "Add Strict Types Declaration" checkbox is selected.
User Interface Integration
Ensure that the checkbox is appropriately integrated into the UI, allowing users to easily toggle the "Add Strict Types Declaration" option during the class/interface creation process.
Benefits:
Enhanced control over the generated PHP code's strict types declaration, aligning with modern PHP development practices.
Provides developers with an easy way to adopt strict typing in their classes, interfaces, and traits from the point of creation.. .
I would like to propose the addition of a new feature in Eclipse PDT that allows developers to include the declare(strict_types = 1); statement in generated PHP classes, interfaces, and traits through respective wizards.
Details:
Benefits:
Enhanced control over the generated PHP code's strict types declaration, aligning with modern PHP development practices. Provides developers with an easy way to adopt strict typing in their classes, interfaces, and traits from the point of creation.. .