diff --git a/zh-cn/application-dev/quick-start/arkts-rendering-control-lazyforeach.md b/zh-cn/application-dev/quick-start/arkts-rendering-control-lazyforeach.md index ff15b61308f857dfa8e28bbbee475d30a2f4060c..d473dc4bb72720cbaa648e38ddbbc8b6b1e1e063 100644 --- a/zh-cn/application-dev/quick-start/arkts-rendering-control-lazyforeach.md +++ b/zh-cn/application-dev/quick-start/arkts-rendering-control-lazyforeach.md @@ -202,7 +202,7 @@ class MyDataSource extends BasicDataSource { @Component struct MyComponent { aboutToAppear() { - for (var i = 100; i >= 80; i--) { + for (let i = 100; i >= 80; i--) { this.data.pushData(`Hello ${i}`) } } @@ -223,7 +223,7 @@ struct MyComponent { .onClick(() => { this.data.pushData(`Hello ${this.data.totalCount()}`); }) - }, item => item) + }, (item: string) => item) }.cachedCount(5) } }