JsonForge · JSON · 업로드 0
JSON이 자기 오류를 직접 가리킵니다.
줄, 열, 그리고 그 글자.
이 탭에서 파싱합니다.
Unexpected token은 새벽 세 시에 아무것도 알려주지 않습니다. 붙여넣으면 JsonForge가 파싱이 깨진 줄·열과 그 글자를 짚고, 포맷한 뒤 어떤 노드든 JSONPath를 복사하는 트리를 열고, 샘플이 함축하는 TypeScript 인터페이스와 Zod 스키마를 쓰고, CSV로 평탄화합니다.
Format, minify, validate
the error is the feature-
Walk the document
click any node · copies its pathKeys that are not plain identifiers are copied in bracket form, $["a-b"].items[0], so the path pastes straight into a JSONPath query. Very large arrays are listed 300 at a time instead of all at once.
Types from a sample
inference, not a contract-
-
An object that appears as {...} inside an array is merged across every element: a field missing from some elements becomes ? / .optional(), and a field that is a string in one and a number in another becomes a union. Empty arrays cannot say what they hold, so they come out as unknown · type them by hand.
Flatten to rows
dotted columns · round tripNested objects become dotted columns; an array stays in one cell as compact JSON, because it has no fixed number of columns. Empty cells are null and missing fields. CSV downloads carry a UTF-8 BOM so Excel opens Korean without mojibake.
-
파싱이 실제로 하는 일
자주 헷갈리는 세 가지01오류는 한 번에 하나
JSON.parse는 받아들일 수 없는 첫 토큰에서 멈추므로, 알려준 글자를 고치면 다음 오류가 드러납니다. 도구가 게으른 것이 아니라, 문법상 잘못된 토큰 너머로 진행할 방법이 없어 모든 파서가 이렇게 동작합니다. 고치고, 다시 붙이고, 반복하세요.
02중복 키는 합법입니다
RFC 8259는 이름이 유일해야 한다고 권고할 뿐 금지하지 않고, 모든 엔진이 마지막 값을 조용히 채택합니다. "port"가 두 번 들어간 설정도 파싱은 되고, 읽기도 전에 덮인 값을 두고 한 시간을 쓰게 됩니다.
03숫자는 정밀도를 잃습니다
JSON 숫자는 IEEE-754 배정도가 되므로 9007199254740993 같은 id는 값이 바뀌어 돌아오고 19자리 계좌 참조번호는 조용히 틀립니다. 긴 식별자는 양쪽 모두 문자열로 주고받으세요.
질문
오류 · 프라이버시 · 타입문법은 맞는데 앱이 계속 거부합니다.
null이 왔거나, 날짜 형식이 다르거나, 숫자를 문자열로 보냈습니다. 실제로 받은 응답을 TypeScript · Zod 탭에 넣고 코드가 기대하는 것과 비교해 보세요. 차이는 대개 옵션 필드 하나, 타입 하나입니다.