日本語のみで絞り込む
2024/10/9 -I explicitly have to add 'Validators.required' and then the form is invalid when you leave the input empty. But I think the regex '[0-9]+' ...
... empty string or an empty array), to support optional controls. You can use the standard required validator if empty values should not be considered valid.
2026/2/3 -Either the documentation should be changed to not include the empty array as empty value for the required validator. Then it would be useful to ...
2025/8/15 -The form control values can be null, because a control can be disabled. A disabled control yields null. getRawValue() returns the form value ...
The <input> element carries the HTML validation attributes: required and minlength . It also carries a custom validator directive, forbiddenName . For more ...
2016/2/6 -The required validator can not really verify the NaN value because it can appear for empty string, but also for string that are not a number ( ...
2023/10/19 -I have a form control typed as number but it doesn't have a initial value. Ok it starts with null, but since it's required is there a way to ...
Empty values and nonnumeric values are left to other validators, such as required . Only props.step enables the validator; setting the HTML attribute ...
2017/1/26 -It can be used in substitution of required because it also treats an empty string as invalid. <input type="text" id="name" myNoSpaces name ...
2023/2/20 -Using Validators.pattern is one approach, and if you're just writing a single component is perfectly acceptable. Here's a Regular Expression ...