restructure project, add claudemd
This commit is contained in:
32
web/runtime/@solidjs/router/dist/data/createAsync.d.ts
vendored
Normal file
32
web/runtime/@solidjs/router/dist/data/createAsync.d.ts
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
import { type ReconcileOptions } from "solid-js/store";
|
||||
/**
|
||||
* As `createAsync` and `createAsyncStore` are wrappers for `createResource`,
|
||||
* this type allows to support `latest` field for these primitives.
|
||||
* It will be removed in the future.
|
||||
*/
|
||||
export type AccessorWithLatest<T> = {
|
||||
(): T;
|
||||
latest: T;
|
||||
};
|
||||
export declare function createAsync<T>(fn: (prev: T) => Promise<T>, options: {
|
||||
name?: string;
|
||||
initialValue: T;
|
||||
deferStream?: boolean;
|
||||
}): AccessorWithLatest<T>;
|
||||
export declare function createAsync<T>(fn: (prev: T | undefined) => Promise<T>, options?: {
|
||||
name?: string;
|
||||
initialValue?: T;
|
||||
deferStream?: boolean;
|
||||
}): AccessorWithLatest<T | undefined>;
|
||||
export declare function createAsyncStore<T>(fn: (prev: T) => Promise<T>, options: {
|
||||
name?: string;
|
||||
initialValue: T;
|
||||
deferStream?: boolean;
|
||||
reconcile?: ReconcileOptions;
|
||||
}): AccessorWithLatest<T>;
|
||||
export declare function createAsyncStore<T>(fn: (prev: T | undefined) => Promise<T>, options?: {
|
||||
name?: string;
|
||||
initialValue?: T;
|
||||
deferStream?: boolean;
|
||||
reconcile?: ReconcileOptions;
|
||||
}): AccessorWithLatest<T | undefined>;
|
||||
Reference in New Issue
Block a user