rut_utils library
Classes
- RutFormatter
- Class to be used as a inputFormatters of a TextFormField. It receives a TextEditingValue and format its value as a Chilean RUT.
Functions
-
deFormatRut(
String rut) → String -
Returns a String with the "." and "-" removed from de
rut
. -
formatRut(
String rut) → String -
Returns a String with "." and "-" added to the
rut
. -
isRutValid(
String rut) → bool -
Evaluates whether the
rut
is valid or not using the oficial algorithim provided by the Chilean government. -
validateRut(
String? rut) → String? -
Returns
null
if the givenrut
is valid.