nobody on Nostr: How do you 𫵠quickly escape your JSON string? Trivial but mega useful when needed ...
How do you 𫵠quickly escape your JSON string? Trivial but mega useful when needed for lots of things š¤·āāļø
`escapy_json '{"key1":"value1","key2":"value2ā}ā`
```
# python command to escape JSON string (minimal py deps)
escapy_json() {
python -c "import json; print(json.dumps('$1'))"
}
```
Published at
2024-01-16 22:28:33Event JSON
{
"id": "c8ca08f7ebae29bac123796656a913f75dbac296cd33b8eef1803b01ea2eaed3",
"pubkey": "89d1ce9164f1f172daaa9c784153178cb1dec7912bf55f5dc07e0f1dabe40e6c",
"created_at": 1705444113,
"kind": 1,
"tags": [],
"content": "How do you 𫵠quickly escape your JSON string? Trivial but mega useful when needed for lots of things š¤·āāļø\n\n`escapy_json '{\"key1\":\"value1\",\"key2\":\"value2ā}ā`\n\n```\n# python command to escape JSON string (minimal py deps)\n\nescapy_json() {\n python -c \"import json; print(json.dumps('$1'))\"\n}\n```",
"sig": "b9559cc3efe74ac7502b6bb3b9c5475941220491e0c11be61cc24022b26908b786729d46c0fccc9eb45c24d78e141621131c4f8175a0cbaaa2bf4a1a4acb87c1"
}