webstudio/ui/src/core/extensions/extensions.ts
2023-11-10 21:43:57 +03:00

18 lines
547 B
TypeScript

import { ArrayExtensions } from "./array";
import { StringExtensions } from "./string";
declare global {
interface Array<T> {
// @strict: The parameter is determined whether the arrays must be exactly the same in content and order of this relationship or simply follow the same requirements.
equals(array: Array<T>, strict: boolean): boolean;
lastElement(): T | undefined;
isEmpty(): boolean;
}
interface String {
isEmpty(): boolean;
}
}
export const extensions = () => {
ArrayExtensions();
StringExtensions();
};