Steady.js

程序名称:Steady.js

授权协议: MIT

操作系统: 跨平台

开发语言: JavaScript

Steady.js 介绍

Steady.js 可实现无闪烁的 onscroll 事件处理,而不会有性能方面的损失。

基本使用方法

<!DOCTYPE html>
<html>
<head>
  <title>Hello world!</title>
</head>
<body>

  <!-- some HTML things here -->
  
  <script type="text/javascript" src="Steady.js"></script>
  <script>
    var s = new Steady({
      conditions: {
        "width": 400px,
        "scrollX": 0,
        "max-bottom": 200px
      },
      throttle: 100,
      handler: fn
    });
  
    // you cann conditions on the fly!
    s.addCondition('scrollX', 0);
  
    function fn(values, done) {
      var xhr = new XMLHttpRequest();
  
      xhr.open('GET', 'imgs.html');
      xhr.onreadystatechange = function() {
        if ( xhr.readyState == 4 ) {
          document.body.innerHTML += xhr.response;
          
          // telling Steady that we're done processing!
          done();
        }
      };
  
      xhr.send();
    }
  
  </script>
</body>
</html>

Steady.js 官网

http://lafikl.github.io/steady.js/

相关编程语言

MuPlayer 是一款跨平台、轻量级的音频播放解决方案,...
OS FLV 是一个 开源和可嵌入网页的flv播放器。 这个...
DewPlayer音乐播放器,样式很简单,而且很实用.播放器...
JW FLV MEDIA PLAYER是一个开源的在网页上使用的Fla...
Speakker 是一个基于 Web 浏览器的音乐播放器,只提...
Player Framework 是一个开源的支持 HTML5 的视频播...