ADVERTISEMENT
Google AdSense Slot (headerLeaderboard)
Set your Publisher ID in src/config/ads.ts to display live ads.
JSON Data Architecture Tutorial• 5 min read
Serialization: JSON.stringify() & Formatting
Serialize JavaScript objects into JSON strings, format readable outputs with indentation, and filter keys with replacers.
Pretty Printing JSON
JSON.stringify(data, null, 2) produces indented, readable JSON ideal for debug logging.
ADVERTISEMENT
Google AdSense Slot (inContentBanner)
Set your Publisher ID in src/config/ads.ts to display live ads.
Test Yourself With Exercise
What third argument passed to JSON.stringify() enables pretty printing with 2-space indentation?