From 7028bd7c9611adfab8b0b43840bed34bb0f1f589 Mon Sep 17 00:00:00 2001 From: Raschid JF Rafaelly Date: Fri, 20 Aug 2021 16:16:37 -0500 Subject: [PATCH 1/3] fix(ts): update definition file --- CHANGELOG.md | 3 +++ package.json | 2 +- src/index.d.ts | 6 +++--- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 57de08a..67c7571 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ # Changelog All notable changes to this project will be documented in this file. +## [2.0.1] - 2021-06-12 +### Fixed +- Update TS definition file ## [2.0.0] - 2021-06-12 ### Added diff --git a/package.json b/package.json index 8048118..d5eedff 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "validate-rfc", - "version": "2.0.0", + "version": "2.0.1", "description": "A simple library to validate mexican RFCs", "main": "dist/index.js", "scripts": { diff --git a/src/index.d.ts b/src/index.d.ts index 4d4fadc..4beaa32 100644 --- a/src/index.d.ts +++ b/src/index.d.ts @@ -1,6 +1,6 @@ -export default function validateRfc(rfc: string, options?: { strict?: boolean }): { +export default function validateRfc(rfc: T, options?: { omitVerificationDigit?: boolean }): { isValid: boolean, type?: 'company' | 'person' | 'foreign' | 'generic', - rfc?: string, - errors?: ('INVALID_FORMAT' | 'INVALID_DATE' | 'INVALID_VERIFICATION_DIGIT' | 'FORBIDDEN_WORD')[] + rfc?: T, + errors?: ('INVALID_FORMAT' | 'INVALID_DATE' | 'INVALID_VERIFICATION_DIGIT' | 'FORBIDDEN_WORD' | 'FORBIDDEN_WORD')[] }; From ac8ad6a9d59a34b2e7216de3e1c6d369cb707070 Mon Sep 17 00:00:00 2001 From: Raschid JF Rafaelly Date: Sat, 21 Aug 2021 11:58:25 -0500 Subject: [PATCH 2/3] fix(ts): remove duplicated error definition --- src/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.d.ts b/src/index.d.ts index 4beaa32..092c569 100644 --- a/src/index.d.ts +++ b/src/index.d.ts @@ -2,5 +2,5 @@ export default function validateRfc(rfc: T, options?: { omitVe isValid: boolean, type?: 'company' | 'person' | 'foreign' | 'generic', rfc?: T, - errors?: ('INVALID_FORMAT' | 'INVALID_DATE' | 'INVALID_VERIFICATION_DIGIT' | 'FORBIDDEN_WORD' | 'FORBIDDEN_WORD')[] + errors?: ('INVALID_FORMAT' | 'INVALID_DATE' | 'INVALID_VERIFICATION_DIGIT' | 'FORBIDDEN_WORD')[] }; From 1463c6c599ec71c56a4ab7c8b8f3875d584644b8 Mon Sep 17 00:00:00 2001 From: Manuel de la Torre Date: Mon, 23 Aug 2021 18:36:29 -0500 Subject: [PATCH 3/3] Update dependencies, use terser instead of uglify --- CHANGELOG.md | 2 +- README.md | 2 +- dist/index.js | 2 +- dist/index.js.map | 2 +- package.json | 14 +- rollup.config.js | 4 +- yarn.lock | 603 ++++++++++++++++++++++++---------------------- 7 files changed, 326 insertions(+), 303 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 67c7571..4b81600 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ # Changelog All notable changes to this project will be documented in this file. -## [2.0.1] - 2021-06-12 +## [2.0.1] - 2021-08-23 ### Fixed - Update TS definition file diff --git a/README.md b/README.md index 3e26402..6476ccf 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ Añade el siguiente script a tu proyecto: - +