rjs-pullload

1.0.51 • Public • Published

下拉刷新及上拉加载

用法

const PullLoad = require('rjs-pullload')

const pullLoad = PullLoad({
  pullDown: true,
  pullUp: true,
  qName: '.pullload',
  bodyQName: '.pullload-body',
  reqMethod: 'POST',
  reqUrl: '',
  reqArgs: {
    type: '{type}',
    page: '{page}',
  },
  reqAjaxFn: Ajax,
  itemRenderFn: function (item, index) {
    return `<p>${item.id} ${item.name}</p>`;
  }
});


样式引用:
require('rjs-pullload/dist/style.css')
或
<link rel="stylesheet" href="....rjs-pullload/dist/style.css"/>

Dependencies (0)

    Dev Dependencies (1)

    Package Sidebar

    Install

    npm i rjs-pullload

    Homepage

    richlee.cn

    Weekly Downloads

    38

    Version

    1.0.51

    License

    MIT

    Unpacked Size

    8.83 kB

    Total Files

    4

    Last publish

    Collaborators

    • artgou