【问题标题】:Bad scroll performance — Famo.us/Angular scrollview滚动性能不佳 — Famo.us/Angular scrollview
【发布时间】:2015-04-22 02:07:01
【问题描述】:

我在使用 Famo.us scrollview 的移动设备上遇到糟糕的滚动性能。我正在使用Famo.us/Angular。这是使用的代码:

<fa-app>
    <fa-scroll-view fa-pipe-from="eventHandler">
        <fa-view ng-repeat="item in items" class="item">

            <fa-surface fa-pipe-to="eventHandler" fa-background-color="'#FA5C4F'" fa-size="[undefined, true]">
                <img ng-src="{{ item.src }}" />
            </fa-surface>

        </fa-view>
    </fa-scroll-view>
</fa-app>

scrollview 选项设置为默认值。一些 Famo.us 演示视频显示完全平滑的滚动。但是,我无法将其转化为实践。因为,我没有修改任何 scrollview 选项并使用准系统模板,我想知道是什么原因造成的。

【问题讨论】:

  • 图片的质量/尺寸如何?如果它们真的是高质量的,它可能会因为图像的加载时间而减慢它们的速度。我很遗憾地在黑暗中拍摄。我用 famo.us 香草。我在香草中使用了大量图像,没有任何麻烦。它是手机尺寸的,所以我没有任何巨型图像。
  • @aintnorest 即使使用 20 张 512x512 大小的图像,我也看到性能不佳。我在 IBM 博客上发布的教程中遇到了一个演示,该演示显示了类似的性能问题(尤其是在 Android 上)。该演示根本不使用任何图像。 famous.mybluemix.net/app4/?cm_mmc=dw--bluemix--wa-着名-_-article
  • 您使用的是哪个版本的着名/著名角度?

标签: famo.us famous-angular


【解决方案1】:

即使是 Javascript 代码也很慢,没有内容!看看这个demo。 性能极差,我认为您在使用前需要三思而后行。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多