Skip to content

Files

Latest commit

f4fa0d3 · Jun 5, 2021

History

History
18 lines (17 loc) · 355 Bytes

javascript-tip.md

File metadata and controls

18 lines (17 loc) · 355 Bytes

JS에서 JSON의 키와 값이 일치하는 경우 생략 가능

JSON 자료구조에 사용되는 Key와 Value가 완전히 동일한 경우 아래와 같이 생략이 가능하다.

JSON.stringify({
    email: email,
    age: age,
    password: password
})
JSON.stringify({
    email,
    age,
    password
})