Luciano655dev / better-format

Um pacote NPM para facilitar a formatação de variaveis e conseguir detalhes sobre elas
8 stars 2 forks source link

Added: ValidateCreditCard #6

Closed Yagasaki7K closed 9 months ago

Yagasaki7K commented 9 months ago

Based on https://github.com/Luciano655dev/better-format/issues/4

This change adds a new function called ValidateCreditCard to the code. The function is designed to validate credit card numbers using the Luhn algorithm, it's worth remembering that it will not verify if that number actually exists, just if it is a valid credit card number.

Function Details

The ValidateCreditCard function accepts a credit card number as input and performs the following checks:

This function can be useful for validating credit card numbers before processing transactions.

Please review and comment on any improvements or suggestions.

Thank you!

Luciano655dev commented 9 months ago

Tudo funcionando normalmente!

Vou atualizar a Doc e melhorar a função, obrigado por contribuir!