- Issue created by @wim leers
- Merge request !1078created new validation constraint for NotNullValueForEveryRequiredSdcProp. โ (Open) created by libbna
- ๐ฎ๐ณIndia libbna New Delhi, India
I've implemented a new validation constraint NotNullValueForEveryRequiredSdcProp to ensure that all required props defined in a component's schema have non-null entries in the default_value mapping. This is based on the required array from the component plugin's metadata schema. The logic closely follows the pattern used in KeyForEverySdcProp.
I've tried to achieve the requirement as describedโplease let me know if anything is missed or needs adjustment.
- ๐ฎ๐ณIndia libbna New Delhi, India
Hi @wim leers to test my code I followed the below steps:
- edit the existing component and remove the default text from the required prop
- saved the component
Let me know if this is correct or have I missed anything?Thanks.
- ๐ง๐ชBelgium wim leers Ghent ๐ง๐ช๐ช๐บ
This is not yet passing tests. ๐ Left a review with pointers.
- ๐ฎ๐ณIndia libbna New Delhi, India
I resolved the phpstan issue by adding " // @phpstan-ignore argument.type" comment by taking reference from
KeyForEverySdcProp
validator file. Please review and let me know if anymore changes are required.
Unassinging myself so that someone else can work for test cases and keeping the issue to needs work only.