mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-02 03:08:21 +08:00
13ffea1114
* refactor(components): refactor ElUpload * refactor(components): refactor upload * test: use jsx * refactor: resolve review comments * fix: ts error * refactor: re-order imports * refactor: rename * fix: infinity watch * refactor: rename * refactor: address PR comments Co-authored-by: Kevin <sxzz@sxzz.moe>
16 lines
455 B
TypeScript
16 lines
455 B
TypeScript
export const mutable = <T extends readonly any[] | Record<string, unknown>>(
|
|
val: T
|
|
) => val as Mutable<typeof val>
|
|
export type Mutable<T> = { -readonly [P in keyof T]: T[P] }
|
|
|
|
export type HTMLElementCustomized<T> = HTMLElement & T
|
|
|
|
/**
|
|
* @deprecated stop to use null
|
|
* @see {@link https://github.com/sindresorhus/meta/discussions/7}
|
|
*/
|
|
export type Nullable<T> = T | null
|
|
|
|
export type Arrayable<T> = T | T[]
|
|
export type Awaitable<T> = Promise<T> | T
|