WORKED CASE · SYNTHETIC TEST DATA

Remove JSON layout without changing a string

Spaces inside a JSON string are data, while indentation is layout. A useful minifier must distinguish the two.

Input and settings

 { "message": "a b", "ok": true } 

Run and interpret

Paste the sample and compress it. The space between a and b must remain even though spaces outside strings disappear.

Expected output

{"message":"a b","ok":true}

Scope and possible misuse

This is not data compression like gzip and does not validate a business schema. Keep original bytes if a signature or byte-for-byte comparison depends on them.

Unexpected result? Report a minimal example