UNPKG

1.47 kBTypeScriptView Raw
1/**
2 * Copyright (C) 2016-2020 Michael Kourlas
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16export declare function isUndefined(val: unknown): val is undefined;
17export declare function isNull(val: unknown): val is null;
18export declare function isObject(val: unknown): val is Record<string, unknown>;
19export declare function isArray(val: unknown): val is unknown[];
20export declare function isFunction(val: unknown): val is Function;
21export declare function isSet(val: unknown): val is Set<unknown>;
22export declare function isMap(val: unknown): val is Map<unknown, unknown>;
23/**
24 * Returns a string representation of the specified value, as given by the
25 * value's toString() method (if it has one) or the global String() function
26 * (if it does not).
27 *
28 * @param value The value to convert to a string.
29 *
30 * @returns A string representation of the specified value.
31 */
32export declare function stringify(value: any): string;