提交 4f9e0081 编写于 作者: 杜庆泉's avatar 杜庆泉

Update uts-plugin.md

上级 4afd27c1
......@@ -581,6 +581,17 @@ let layoutParam = new FrameLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARE
function connectWifi(option: WifiConnectOption,testName :string = "zhangsan")
```
### 访问JSON对象属性
`uts`环境中访问`JSON`对象的属性,不能用`user.age` 而要用 `user['age']`
```ts
let jsonContent = "{'username':'zhangsan','age':12}"
let jsonObj = JSON.parse(jsonContent);
console.log("jsonObj['age'] == " + jsonObj['age'] );
```
## 路线图
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册