@tb-dev/utils 1.7.3 → 1.7.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -37,7 +37,7 @@ exports.todo = panic.todo;
37
37
  exports.unimplemented = panic.unimplemented;
38
38
  exports.unreachable = panic.unreachable;
39
39
  exports.splitWhitespace = string.splitWhitespace;
40
- exports.flush = promise.flush;
40
+ exports.flushPromises = promise.flushPromises;
41
41
  exports.sleep = promise.sleep;
42
42
  exports.isEmpty = isEmpty;
43
43
  exports.isNullish = isNullish;
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@ import { regex } from "./regex.js";
2
2
  import { toArray, trimArray, upsert } from "./array.js";
3
3
  import { panic, todo, unimplemented, unreachable } from "./panic.js";
4
4
  import { splitWhitespace } from "./string.js";
5
- import { flush, sleep } from "./promise.js";
5
+ import { flushPromises, sleep } from "./promise.js";
6
6
  function isEmpty(value) {
7
7
  if (isNullish(value)) {
8
8
  return true;
@@ -27,7 +27,7 @@ function toPixel(value) {
27
27
  return value;
28
28
  }
29
29
  export {
30
- flush,
30
+ flushPromises,
31
31
  isEmpty,
32
32
  isNullish,
33
33
  noop,
package/dist/promise.cjs CHANGED
@@ -1,11 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const scheduler = typeof setImmediate === "function" ? setImmediate : setTimeout;
4
- function flush() {
4
+ function flushPromises() {
5
5
  return new Promise((resolve) => void scheduler(resolve, 0));
6
6
  }
7
7
  function sleep(ms) {
8
8
  return new Promise((resolve) => void setTimeout(resolve, ms));
9
9
  }
10
- exports.flush = flush;
10
+ exports.flushPromises = flushPromises;
11
11
  exports.sleep = sleep;
package/dist/promise.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare function flush(): Promise<void>;
1
+ export declare function flushPromises(): Promise<void>;
2
2
  export declare function sleep(ms: number): Promise<void>;
package/dist/promise.js CHANGED
@@ -1,11 +1,11 @@
1
1
  const scheduler = typeof setImmediate === "function" ? setImmediate : setTimeout;
2
- function flush() {
2
+ function flushPromises() {
3
3
  return new Promise((resolve) => void scheduler(resolve, 0));
4
4
  }
5
5
  function sleep(ms) {
6
6
  return new Promise((resolve) => void setTimeout(resolve, ms));
7
7
  }
8
8
  export {
9
- flush,
9
+ flushPromises,
10
10
  sleep
11
11
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tb-dev/utils",
3
- "version": "1.7.3",
3
+ "version": "1.7.5",
4
4
  "description": "TypeScript utils",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -27,10 +27,10 @@
27
27
  "*.{?(c|m)@(j|t)s,vue}": "pnpm run lint"
28
28
  },
29
29
  "dependencies": {
30
- "@tb-dev/utility-types": "^1.3.0"
30
+ "@tb-dev/utility-types": "^1.3.1"
31
31
  },
32
32
  "devDependencies": {
33
- "@tb-dev/eslint-config": "^3.5.1",
33
+ "@tb-dev/eslint-config": "^3.6.0",
34
34
  "@types/node": "^20.12.11",
35
35
  "eslint": "^8.57.0",
36
36
  "husky": "^9.0.11",
@@ -38,7 +38,7 @@
38
38
  "prettier": "^3.2.5",
39
39
  "tslib": "^2.6.2",
40
40
  "typedoc": "^0.25.13",
41
- "typedoc-plugin-mdn-links": "^3.1.24",
41
+ "typedoc-plugin-mdn-links": "^3.1.25",
42
42
  "typescript": "^5.4.5",
43
43
  "vite": "^5.2.11",
44
44
  "vite-plugin-dts": "^3.9.1"