This report is effective as of MAY 21, 2021.
dependencies:
form_field_validator: ^1.1.0
import 'package:form_field_validator/form_field_validator.dart';
<省略>
final formKey = GlobalKey<FormState>();
<省略>
TextFormField(
validator: RequiredValidator(errorText: "fill in"),
),
<省略>
onPressed: () {
if (formKey.currentState.validate()) { formKey.currentState.save();
print("확인 = ~~);
}
as below example
validator: MultiValidator([
EmailValidator(errorText: "이메일 형식에 맞질 않습니다."),
RequiredValidator(errorText: "이메일을 입력하세요")
]),
cf. keyboardType: TextInputType.emailAddress
End
⊙^⊙ Thank For Reading | Happy Coding ⊙-⊙
The referrer gets a free month, up to a maximum of six months, for each friend who creates an account and signs in on their Mac.