Coder Social home page Coder Social logo

vue-list's Introduction

vue-list

npm npm vue2

基于 Vant List 组件封装的 Vue.js 插件。

目录

安装

npm install --save @lucky-joel/vue-list

使用

<template>
<ul>
  <lj-list 
    url="/singer/list"
  >
    <template slot-scope="scope" v-if="scope.data">
      <li>{{scope.data.name}}</li>
    </template>
  </lj-list>
</ul>

</template>
<script>
import Vue from 'vue'
import List from '@lucky-joel/vue-list'
Vue.use(List)

export default {
  ...
}
</script>

参数:

  • url: 接口地址。必填。
  • page-limit: 每页条数。默认五条。
  • search-condition: 搜索条件。 对象类型。
  • order: 分页。数组类型。 形如 ['name', 'desc或asc']
  • is-infinate: 是否无限加载。 默认是。

构建

npm run build

发布到 npm

npm run build
npm publish --access public

License

MIT

vue-list's People

Contributors

iamjoel 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.