what is json
{
"first_name": "Taylor",
"last_name": "Hawkes",
"age": 31,
"address": {
"street": "954 Kazaam Lane",
"city": "Boulder",
"state": "CO",
"postalCode": "80303"
},
"emails": [
{
"type": "main",
"number": "[email protected]"
},
{
"type": "secondary",
"number": "[email protected]"
}
]
}JavaScript Object Notation
Its a key value pair
its popular light-weight way of transfering data
for example :
Lets try to create a json for Person Object
with name , age , isMarried , gender
Its ket value pair
the key is always String and need to be in quotation
value can be :
String
Number
Boolean
null
array
another json object
This is one json with 5 fields
each key value pair should be separated by comma
{
"name" : "Anna",
"age" : 18 ,
"isMarried" : false ,
"gender" : "female",
"company" : null
}JSON = JavaScript Object Notation{
"name" : "data"
}{
}
Also in JavaScript:
- events js 292 throw er Unhandled 'error' event ^ Error getaddrinfo ENOTFOUND x86_64-apple-darwin13.4.0 at GetAddrInfoReqWrap.onlookup [as oncomplete]
- javascript push in specific index
- site completo com ajax jquery
- remarkable react js
- js get element padding
- javascript get point of line intersection
- how to replace characters in a string javascript
- program to parenthesize an expression
- flutter betterplayer get aspect ratio
- create server and connect to db and frontend
- npm font awesome vue
- reverse an array javascript
- javascript redirect new window
- Vuejs v-model when enter pressed
- react js installation
- quicksort javascript
- javascript localstorage
- angular on back skip routes
- attr hidden to show jquery
- javascript detect touch screen
- how to integrate vuejs with nodejs and express
- luxurious
- rematch config
- Regular Expressions: Find More Than the First Match