需要帮助修复homebridge插件的JSON吗
需要帮助修复homebridge插件的JSON语法。我一直在使用jsonlint,但无法确定如何修复下面的代码,以便语法正确需要帮助修复homebridge插件的JSON吗,json,Json,需要帮助修复homebridge插件的JSON语法。我一直在使用jsonlint,但无法确定如何修复下面的代码,以便语法正确 { "bridge": { "name": "Homebridge", "username": "xxx", "port": 51826, "pin": "xxx" }, "accessories": [], "platforms": [{ "n
{
"bridge": {
"name": "Homebridge",
"username": "xxx",
"port": 51826,
"pin": "xxx"
},
"accessories": [],
"platforms": [{
"name": "Config",
"port": 8080,
"auth": "form",
"log": {
"method": "file",
"path": "/Users/xx/.homebridge/homebridge.log" ["platform": "config"]
} {
"platform": "DysonPlatform",
"name": "DysonPlatform",
"email": "xxx",
"password": "xxx",
"country": "US"
"accessories": [{
"ip": "xxx",
"displayName": "Dyson",
"serialNumber": "xxx"
},
{
"ip": "ip of your second device",
"displayName": "Name to be shown on Home App",
"serialNumber": "DYSON-XXX-XX-XXXXXXXX-XXX",
"password": "password of your second device"
}
]
}
],
格式化JSON
{
"bridge": {
"name": "Homebridge",
"username": "xxx",
"port": 51826,
"pin": "xxx"
},
"accessories": [],
"platforms": [{
"name": "Config",
"port": 8080,
"auth": "form",
"log": {
"method": "file",
"path": "/Users/xx/.homebridge/homebridge.log",
"platform": "config"
}
},
{
"platform": "DysonPlatform",
"name": "DysonPlatform",
"email": "xxx",
"password": "xxx",
"country": "US",
"accessories": [{
"ip": "xxx",
"displayName": "Dyson",
"serialNumber": "xxx"
}, {
"ip": "ip of your second device",
"displayName": "Name to be shown on Home App",
"serialNumber": "DYSON-XXX-XX-XXXXXXXX-XXX",
"password": "password of your second device"
}]
}
]
}
给自己找一个JSON linter(提示:Google)并把JSON放进去,然后看看它在抱怨什么。此外,您可能希望将其格式化为人类可以使用的东西。