@talend/utils
Advanced tools
Comparing version 1.4.5 to 2.0.0
# @talend/utils | ||
## 2.0.0 | ||
### Major Changes | ||
- d5f261f49: utils: remove default export, use named exports instead | ||
- WHAT the breaking change is | ||
Remove default export of @talend/utils package, use named exports instead | ||
- WHY the change was made | ||
The utils package used a default export. so we can't do a destruction import as readme described: | ||
``` | ||
import { validation } from '@talend/utils'; | ||
``` | ||
- HOW a consumer should update their code | ||
Use destruction import like `import { validation, date } from '@talend/utils';` to replace default import. | ||
## 1.4.5 | ||
@@ -4,0 +19,0 @@ |
@@ -1,27 +0,3 @@ | ||
declare const _default: { | ||
date: { | ||
convertToLocalTime: typeof import("./date").convertToLocalTime; | ||
convertToTimeZone: typeof import("./date").convertToTimeZone; | ||
convertToUTC: typeof import("./date").convertToUTC; | ||
format: typeof import("./date").format; | ||
FORMAT: { | ||
MDY_LONG: string; | ||
MY_LONG: string; | ||
MDY: string; | ||
MDYHM: string; | ||
}; | ||
formatReadableUTCOffset: typeof import("./date").formatReadableUTCOffset; | ||
formatToTimeZone: typeof import("./date").formatToTimeZone; | ||
getUTCOffset: typeof import("./date").getUTCOffset; | ||
timeZoneExists: typeof import("./date").timeZoneExists; | ||
}; | ||
validation: { | ||
validFirstName: Function; | ||
validLastName: Function; | ||
validEmail: Function; | ||
validDomain: Function; | ||
validPhone: Function; | ||
REGEXP: typeof import("./validation/regexp"); | ||
}; | ||
}; | ||
export default _default; | ||
import date from './date'; | ||
import validation from './validation'; | ||
export { date, validation }; |
@@ -6,5 +6,7 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.validation = exports.date = void 0; | ||
var date_1 = __importDefault(require("./date")); | ||
exports.date = date_1.default; | ||
var validation_1 = __importDefault(require("./validation")); | ||
exports.default = { date: date_1.default, validation: validation_1.default }; | ||
exports.validation = validation_1.default; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@talend/utils", | ||
"version": "1.4.5", | ||
"version": "2.0.0", | ||
"description": "Various utilities", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
import date from './date'; | ||
import validation from './validation'; | ||
export default { date, validation }; | ||
export { date, validation }; |
Sorry, the diff of this file is not supported yet
71617
1237