es-toolkit 1.39.7-dev.1443 → 1.39.7-dev.1448

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.
@@ -1,16 +1,17 @@
1
1
  /**
2
2
  * Creates a function that is restricted to invoking func once. Repeat calls to the function return the value of the first invocation.
3
3
  *
4
- * @template T - The type of the function.
5
- * @param {T} func - The function to restrict.
6
- * @returns {T} Returns the new restricted function.
4
+ * @template F - The type of the function.
5
+ * @param {F} func - The function to restrict.
6
+ * @returns {F} Returns the new restricted function.
7
7
  *
8
8
  * @example
9
- * var initialize = once(createApplication);
9
+ * const initialize = once(createApplication);
10
+ *
10
11
  * initialize();
11
12
  * initialize();
12
13
  * // => `createApplication` is invoked once
13
14
  */
14
- declare function once<T extends (...args: any) => any>(func: T): T;
15
+ declare function once<F extends (...args: any[]) => any>(func: F): F;
15
16
 
16
17
  export { once };
@@ -1,16 +1,17 @@
1
1
  /**
2
2
  * Creates a function that is restricted to invoking func once. Repeat calls to the function return the value of the first invocation.
3
3
  *
4
- * @template T - The type of the function.
5
- * @param {T} func - The function to restrict.
6
- * @returns {T} Returns the new restricted function.
4
+ * @template F - The type of the function.
5
+ * @param {F} func - The function to restrict.
6
+ * @returns {F} Returns the new restricted function.
7
7
  *
8
8
  * @example
9
- * var initialize = once(createApplication);
9
+ * const initialize = once(createApplication);
10
+ *
10
11
  * initialize();
11
12
  * initialize();
12
13
  * // => `createApplication` is invoked once
13
14
  */
14
- declare function once<T extends (...args: any) => any>(func: T): T;
15
+ declare function once<F extends (...args: any[]) => any>(func: F): F;
15
16
 
16
17
  export { once };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "es-toolkit",
3
3
  "description": "A state-of-the-art, high-performance JavaScript utility library with a small bundle size and strong type annotations.",
4
- "version": "1.39.7-dev.1443+eb19b6f0",
4
+ "version": "1.39.7-dev.1448+3a2def27",
5
5
  "homepage": "https://es-toolkit.dev",
6
6
  "bugs": "https://github.com/toss/es-toolkit/issues",
7
7
  "repository": {