This repository has been archived by the owner on Nov 16, 2018. It is now read-only.
Releases: dhershman1/simple-card
Releases · dhershman1/simple-card
v2.2.0
New
- Added unit tests for internal functions
Improved
- Added my Kyanite Library to make use of utilities
- Fixed current linter issues
- Removed slow
for in
loop for getting the card type - Made expired functionality no longer statically use
20
if only 2 digits are passed in for a year - Heavy optimizations to
cvn
functionality- Removed unneeded processing
- Cleaned up code base
- Removed unneeded code
- Optimizations to
match
functionality - Tweaked Luhn Algorithm for easier catch on non-number cards
- Code optimizations within the number validation function
- Re wrote card type functionality from the ground up, improving performance
- Rebuilt validation flow taking advantage of the Kyanite library
- Re structured the flow of the expired functionality
- Updated all dev dependencies
- Better sanitization of data, cleaning up non-digits from data strings
v2.1.2
- Hotfix for documentation bug
v2.1.1
Improved
- Added a category tag to the documentation
- Tweaked the automated scripts to make sure the main documentation site stays up to date a lot faster and easier
v2.1.0
Note this is mainly a huge architecture upgrade so the library will still work the same
- Converted linter to
standardjs
instead ofeslint
- Flattened out the files so src is a folder of js files now with internals being a folder of internal js files
- Moved tests into their own folder at root level
- Enhanced backend automation scripts for better performance
- Brought all dev dependencies up to date
- Swapped out
webpack
in favor ofrollup
- Added a
simple-card.js
which can be used in dev instances to get better error logs
v2.0.1
- Fixed all unit tests to actually get full year
- Fixed expired functionality to be able to handle invalid dates
v2 Release
Breaking Changes
- Removed the ability to send single strings into the main function (call the individual functions)
- Removed the ability to send partial objects to the main function
- Changed the expected card object property name from
expire
todate
New
number
which can be used to validate a credit card numbercvn
which can be used to validate a credit card cvn/security codeexpired
which can be used to validate a credit cards expiration datematches
which can be used to see if a cvn and a card number match (the cvn length matches the card type)validation
which is the core functionality and only accepts an object- A match property was added to the results that says if it failed by a rule or if it failed matching
- Type Errors have been added when the correct type of value isn't provided (String or Number)
- Converted to a webpack build along with automation scripts for docs, and building files
- README has been updated with all the needed changes
Fixes
- Improved the overall structure of the code which allowed removal of a lot of internals
- Cleaner organization now that the module isn't supporting so many different types
v1.4.0 Release
- Added: Defaults for most validation methods
- Added: Type Checks for each validation method
- Note: Type errors will be thrown if invalid types are passed through (Arrays, Objects, etc.)
- Added: Some better documentation to methods
- Added: Tests for all of these main changes
- Changed: Re organized some internal methods to live where they are being used since they are not being re used
- Changed: Updated all Dev dependencies
- Fixed: Tests to no longer use hardcoded dates (Unless its a test on expired dates)
- Fixed: Code to meet new ESlint version linting errors
- Fixed: Rollup config for new version