Coder Social home page Coder Social logo

i-page's Introduction

i-page

基于knockout的分页组件

  1. 用法简单
  2. 可用于同步分页与异步分页

用法

  • 使用全部参数
<i-page params="{iChange:pageChange,watch:[searchKey,status],buttonNum:9}"></i-page>
  • 最简用法
<i-page params="{iChange:pageChange}"></i-page>
  self.pageNoChange = function (pageNo, pageSize, callback) {
            self.pageNo(pageNo);           
            callback(self.list().length);
        };
  • html参数说明

    iChange

    当页码发生改变时,被组件调用

    watch

    传入需要跟踪变化的参数

    buttonNum

    显示分页按钮个数,默认为5

  • javascript参数说明

    pageNo

    当前页码

    pageSize

    当前分页大小

    callback

    调用重新生成按钮

关于作者

如有bug,请联系 [email protected]

i-page's People

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.