现在 Controller 已弃用,我应该使用什么代替? [英] Now that Controller is deprecated, what do I use instead?
问题描述
我有两个顶级控制器,现在 Controller
已弃用,我想知道如何将它们转换为所需的任何内容.
I have two top level controllers, and now that Controller
is deprecated, I'm wondering how to convert them to whatever it is they need to be.
推荐答案
在对类似问题的回答 中已经提到,即使 Controller
已被弃用,但目前还没有替代品,但会在 1.0 之前.
In the answer of a similar question it was already mentioned that even though Controller
is already deprecated there is no replacement yet but will be before 1.0.
据我从最近的问题更新中了解到,Template
计划成为 Controller
和 Decorator
/Directive 的替代品代码>.我还没有检查,但我认为它尚未在 0.11.0 中发布.
As far as I read from recent issue updates Template
is planned to become the replacement for Controller
and Decorator
/Directive
. I haven't checked but I think it is not yet shipped in 0.11.0.
我的理解是Template
是Controller
和Component
的组合,没有shadowDOM.
My understanding is that Template
is a combination of Controller
and Component
without shadowDOM.
这篇关于现在 Controller 已弃用,我应该使用什么代替?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!