<分区>
编辑问题以包含 desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem .这将有助于其他人回答问题。
关闭 5 年前。
标签 javascript html css reactjs
<分区>
编辑问题以包含 desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem .这将有助于其他人回答问题。
关闭 5 年前。
我在使用 bootstrap 设置的静态 html 页面上添加了一些图表,效果很好。迁移到 React 后,我遇到了一个奇怪的 React 前端故障,如下图所示...
图 1 显示了滚动时的外观以及滚动结束后的短时间。
滚动结束后,页面会重新呈现并正确显示。当子组件被渲染时,我只计算一次图表输入。滚动不会导致重新渲染。
最佳答案
错误是由animate.css引起的.来自 here 的公认解决方案成功了:
.animated {
-webkit-animation: fade-in 1s linear 1001ms, fade-out 1s linear 3s;
-webkit-animation-fill-mode: forwards;
}
关于javascript - 使用 react 时的前端故障,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46698533/