基金会和AngularJS [英] Foundation and AngularJS
问题描述
我修改使用响应速度和AngularJS Zurb的Foundation框架的应用程序。有一个地方与&LT显示在一个表中的数据错误; TR NG重复=OBJ中的条目> ...< / TR>
的< TD>
的,这是隐藏/根据基金会的响应规则中。不幸的是,当角模型被更新,基金会不会重新流动的新呈现的DOM
I am modifying an application using Zurb's Foundation framework for responsiveness and AngularJS. There is a bug where data displayed in a table with <tr ng-repeat="obj in entries">...</tr>
has <td>
's which are hidden/shown based on Foundation's responsive rules. Unfortunately, when the angular model is updated, Foundation doesn't re-flow the newly rendered DOM.
我已经尝试使用的$(document).foundation('表')
我在谷歌大量搜索发现,但这实际上并没有触发响应的回流倒塌表。我还增加了一个指令触发一个简单的 $(窗口).trigger('调整')
这适用于第一个呼叫,但任何后续调用没有。
I have tried using
$(document).foundation('table')
as I found in extensive google searching, but this didn't actually trigger a reflow of the responsive collapsed table. I also added a directive to trigger a simple $(window).trigger('resize')
which works for the first call, but any subsequent calls do not.
任何人遇到了这个?
推荐答案
您在混合的不发挥好在一起的技术。
You are mixing two technologies that dont play nice together.
由Zurb基金会提供的JS资产将不可避免地与AngularJS消化周期冲突。出于这个原因---角引导项目出现了jQuery插件转换成AngularJS指令。
The JS assets provided by Zurb Foundation will inevitably have conflicts with the digest cycle in AngularJS. For this reason --- Angular-Bootstrap projects emerged to transform jquery plugins into AngularJS directives.
http://angular-ui.github.io/bootstrap/
我不相信同样的支持水平,如果有的话,供Zurb基金会。
I don't believe the same level of support, "if any", is offered for Zurb Foundation.
这篇关于基金会和AngularJS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!