card_number_formatter library

Classes

CardNumberFormatter

Functions

separateCardNumberGroups(String spacelessCardNumber, String brand) → List<String>
Separates a card number according to the brand requirements, including prefixes of card numbers, so that the groups can be easily displayed if the user is typing them in. Note that this does not verify that the card number is valid, or even that it is a number. [...]