JSON 포매터
JSON을 정리하고 검증하고 압축하며, 접고 펼칠 수 있는 트리로 탐색하고 JSONPath로 필터링합니다. 깨진 문법은 자동으로 고치고 TypeScript 인터페이스나 Zod 스키마도 만들어 줍니다.
브라우저 안에서만 실행됩니다. 입력한 내용은 어디에도 업로드되지 않습니다.
키, $, [0], 배열 와일드카드 [*], 객체 와일드카드 * — 예: $.posts[*].slug. 출력과 트리는 필터를 따르며, 비워 두면 문서 전체를 씁니다.
{
"id": 42,
"name": "RYUSLOG DEV",
"tags": [
"json",
"typescript"
],
"owner": {
"handle": "r39",
"verified": true
},
"posts": [
{
"slug": "json-format",
"views": 1200
},
{
"slug": "jwt-decode",
"views": 860
}
]
}포매팅은 브라우저에서 실행됩니다. 잘못된 JSON도 어디로도 전송되지 않습니다.
JSON 치트시트
빠른 참조- JSON.parse(text)
- JSON 문자열을 값으로 파싱합니다. 마지막 쉼표나 홑따옴표가 있으면 SyntaxError가 납니다.
- JSON.stringify(value, null, 2)
- 2칸 들여쓰기로 보기 좋게 출력합니다. 세 번째 인자에는 공백 문자열이나 칸 수를 넣습니다.
- undefined, function
- 객체에서는 사라지지만 배열 안에서는 직렬화할 때 null로 바뀝니다.
- Date
- toJSON()을 거쳐 직렬화되므로 항상 2026-11-16T05:00:00.000Z 같은 ISO 8601 문자열이 됩니다.
- "{\"a\":1}"
- 로그나 환경 변수에 이스케이프된 채 저장된 JSON은 파싱 전에 한 번 풀어야 합니다.
- $.posts[*].slug
- 경로 필터용 JSONPath입니다. $는 루트, .key는 객체 키, [0]은 배열 인덱스, [*]는 모든 항목을 뜻합니다.
TypeScript 관련 문법 가이드
TypeScript 가이드 전체Zod infer vs TypeScript Interfaces: Runtime Validation Gaps
An interface validates nothing, z.infer is the output type and not the input, and Zod 4 renamed the error helpers. What each one actually guarantees.
TypeScriptTypeScript Decorators: Standard vs experimentalDecorators
TS1240 appears when a legacy decorator meets the stage 3 transform, and the reverse breaks NestJS DI. How the two signatures differ and which flag each stack needs.
TypeScriptTS2307 and TS2835: Cannot Find Module Under moduleResolution NodeNext
NodeNext models Node's real resolution, so .js belongs in the source import and exports maps decide what exists. Why bundler resolution hides both errors.
TypeScriptTypeScript strict Mode: TS2531, TS7006, and TS18047 Migrations
strict is nine flags at once. Count errors per code, fix them in the order that keeps the build green, and narrow instead of asserting.