@tanstack/table-core 8.1.2 → 8.1.4
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/build/cjs/utils.js +2 -2
- package/build/cjs/utils.js.map +1 -1
- package/build/esm/index.js +2 -2
- package/build/esm/index.js.map +1 -1
- package/build/stats-html.html +1 -1
- package/build/stats-react.json +301 -301
- package/build/types/index.d.ts +1 -1
- package/build/umd/index.development.js +2 -2
- package/build/umd/index.development.js.map +1 -1
- package/build/umd/index.production.js.map +1 -1
- package/package.json +1 -1
- package/src/utils.ts +6 -3
package/build/types/index.d.ts
CHANGED
|
@@ -668,7 +668,7 @@ declare type UnionToIntersection<T> = (T extends any ? (x: T) => any : never) ex
|
|
|
668
668
|
declare type IfDefined<T, N> = 0 extends 1 & T ? N : T extends {} ? T : N;
|
|
669
669
|
declare function functionalUpdate<T>(updater: Updater<T>, input: T): T;
|
|
670
670
|
declare function noop(): void;
|
|
671
|
-
declare function makeStateUpdater(key:
|
|
671
|
+
declare function makeStateUpdater<K extends keyof TableState>(key: K, instance: unknown): (updater: Updater<TableState[K]>) => void;
|
|
672
672
|
declare type AnyFunction = (...args: any) => any;
|
|
673
673
|
declare function isFunction<T extends AnyFunction>(d: any): d is T;
|
|
674
674
|
declare function flattenBy<TNode>(arr: TNode[], getChildren: (item: TNode) => TNode[]): TNode[];
|
|
@@ -19,9 +19,9 @@
|
|
|
19
19
|
}
|
|
20
20
|
function noop() {//
|
|
21
21
|
}
|
|
22
|
-
function makeStateUpdater(key,
|
|
22
|
+
function makeStateUpdater(key, instance) {
|
|
23
23
|
return updater => {
|
|
24
|
-
|
|
24
|
+
instance.setState(old => {
|
|
25
25
|
return { ...old,
|
|
26
26
|
[key]: functionalUpdate(updater, old[key])
|
|
27
27
|
};
|