$ gnpm install @bconnorwhite/json-types
Type checking for json objects
yarn add @bconnorwhite/json-types
import { isJSONObject, JSONObject, JSONValue, JSONArray } from "@bconnorwhite/json-types";
isJSONObject(object?: JSONValue): boolean;
type JSONObject = {
[key in string]?: JSONValue
};
type JSONValue = string | number | boolean | null | JSONObject | JSONArray;
interface JSONArray extends Array<JSONValue> {};
Copyright 2013 - present © cnpmjs.org | Home |