@vitest/utils
Advanced tools
@@ -78,4 +78,5 @@ import { Nullable, Arrayable } from './types.js'; | ||
| declare function unique<T>(array: T[]): T[]; | ||
| declare function sanitizeFilePath(s: string): string; | ||
| export { assertTypes, cleanUrl, clone, createDefer, createSimpleStackTrace, deepClone, deepMerge, filterOutComments, getCallLastIndex, getOwnProperties, getType, isBareImport, isExternalUrl, isNegativeNaN, isObject, isPrimitive, nanoid, noop, notNullish, objectAttr, ordinal, shuffle, slash, splitFileAndPostfix, toArray, unique, unwrapId, withTrailingSlash, wrapId }; | ||
| export { assertTypes, cleanUrl, clone, createDefer, createSimpleStackTrace, deepClone, deepMerge, filterOutComments, getCallLastIndex, getOwnProperties, getType, isBareImport, isExternalUrl, isNegativeNaN, isObject, isPrimitive, nanoid, noop, notNullish, objectAttr, ordinal, sanitizeFilePath, shuffle, slash, splitFileAndPostfix, toArray, unique, unwrapId, withTrailingSlash, wrapId }; | ||
| export type { DeferPromise }; |
+5
-1
@@ -343,3 +343,7 @@ import { VALID_ID_PREFIX, NULL_BYTE_PLACEHOLDER } from './constants.js'; | ||
| } | ||
| function sanitizeFilePath(s) { | ||
| // eslint-disable-next-line no-control-regex | ||
| return s.replace(/[\x00-\x2C\x2E\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]+/g, "-"); | ||
| } | ||
| export { assertTypes, cleanUrl, clone, createDefer, createSimpleStackTrace, deepClone, deepMerge, filterOutComments, getCallLastIndex, getOwnProperties, getType, isBareImport, isExternalUrl, isNegativeNaN, isObject, isPrimitive, nanoid, noop, notNullish, objectAttr, ordinal, shuffle, slash, splitFileAndPostfix, toArray, unique, unwrapId, withTrailingSlash, wrapId }; | ||
| export { assertTypes, cleanUrl, clone, createDefer, createSimpleStackTrace, deepClone, deepMerge, filterOutComments, getCallLastIndex, getOwnProperties, getType, isBareImport, isExternalUrl, isNegativeNaN, isObject, isPrimitive, nanoid, noop, notNullish, objectAttr, ordinal, sanitizeFilePath, shuffle, slash, splitFileAndPostfix, toArray, unique, unwrapId, withTrailingSlash, wrapId }; |
+2
-2
| { | ||
| "name": "@vitest/utils", | ||
| "type": "module", | ||
| "version": "5.0.0-beta.1", | ||
| "version": "5.0.0-beta.2", | ||
| "description": "Shared Vitest utility functions", | ||
@@ -89,3 +89,3 @@ "license": "MIT", | ||
| "tinyrainbow": "^3.1.0", | ||
| "@vitest/pretty-format": "5.0.0-beta.1" | ||
| "@vitest/pretty-format": "5.0.0-beta.2" | ||
| }, | ||
@@ -92,0 +92,0 @@ "devDependencies": { |
147179
0.17%4110
0.12%+ Added
- Removed