diff --git a/en/application-dev/reference/apis/js-apis-display.md b/en/application-dev/reference/apis/js-apis-display.md index 22ea52f17d7b5996d536c8dc223ada7ee9ae1fa2..994fe3a673ca9d505c0a6f96df6f007fe6d027d4 100644 --- a/en/application-dev/reference/apis/js-apis-display.md +++ b/en/application-dev/reference/apis/js-apis-display.md @@ -168,11 +168,10 @@ Enables listening. **Example** ```js - var type = "add"; var callback = (data) => { console.info('Listening enabled. Data: ' + JSON.stringify(data)) } - display.on(type, callback); + display.on("add", callback); ``` @@ -192,6 +191,5 @@ Disables listening. **Example** ```js - var type = "remove"; - display.off(type); + display.off("remove"); ```