JSON Data Types
Multiple Choice Easy
Question
Which is NOT a valid JSON data type?
Hint
JSON supports: string, number, boolean, null, array, object.
Explanation
undefined is not a valid JSON value. JSON supports six data types: string, number, boolean, null, array, and object. undefined is a JavaScript concept that has no representation in JSON. This is why JSON.stringify({x: undefined}) omits the property entirely.
Related Resources
Related Lessons
- JSON
Learn JSON data format.
Look up unfamiliar terms
A beginner-friendly glossary explains jargon in plain English — variables, functions, DOM, Promise, and more.
Decode error messages
Plain-English explanations of common errors — what they mean, why they happen, and how to fix them.
Build real projects
Apply what you learned by building guided projects with starter code and solutions.