一些语法格式的特点:
Html:
<></>
xx=””
json:
{
“”:””,
}
数组中可以嵌套对象,数组
css:
@xx{ //@代表某些符号,比如.
xxx:yyy;
}
JS:
{
xxx:" ",
xxx:" "
}
方法:
JS
1.function test( ){
}
2.Const test=function( ){ } //定义一个常量
3.const test=( )=>{……}
JSON例子:
{
"name": "John Smith",
"age": 30,
"address": {
"street": "123 Main St",
"city": "New York",
"state": "NY",
"postalCode": "10001"
},
"email": [
"john@example.com",
"john.smith@example.com"
],
"phone": {
"home": "555-1234",
"work": "555-5678"
},
"isEmployed": true,
"languages": ["English", "Spanish", "French"]
}
也就是对象,数组,布尔型,数值型可以不用加"",字符串类型要加""