From 2454872af0ef1eb5c87ee6cc9da5b79732b425ad Mon Sep 17 00:00:00 2001 From: guy Date: Tue, 7 Dec 2021 19:44:30 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=AF=E6=8C=81BI.useContext?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- examples/useContext.html | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/examples/useContext.html b/examples/useContext.html index 8762ba34c..2c23788cf 100644 --- a/examples/useContext.html +++ b/examples/useContext.html @@ -40,14 +40,17 @@ setInterval(function () { context.toggle(); }, 1000); - BI.watch(context, "expand", function () { - label.setText(context.model.text); - }); + // BI.watch(context, "expand", function () { + // label.setText(context.model.text); + // }); return { type: "bi.label", ref: function (_ref) { label = _ref; }, + effect: function (w) { + w.setText(context.model.text) + }, text: function () { return context.model.text; }