UNPKG

@yookue/ts-lang-utils

Version:

Common lang utilities for typescript

9 lines 459 B
export function equalsIgnoreCase(text, comparison) { if (text === comparison) { return true; } if (!text || !comparison || (text === null || text === void 0 ? void 0 : text.length) !== (comparison === null || comparison === void 0 ? void 0 : comparison.length)) { return false; } return (text === null || text === void 0 ? void 0 : text.toUpperCase()) === (comparison === null || comparison === void 0 ? void 0 : comparison.toUpperCase()); }