Last active
September 1, 2025 18:27
-
-
Save erikpukinskis/bd9c3aee59a1fad358bef35abf86896d to your computer and use it in GitHub Desktop.
TypeScript type for arbitrary JSON values
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * TypeScript types for arbitrary JSON values | |
| */ | |
| type JsonPrimitive = string | number | boolean | null; | |
| type JsonArray = JsonValue[]; | |
| type JsonObject = { [key: string]: JsonValue }; | |
| type JsonValue = JsonPrimitive | JsonObject | JsonArray; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment