JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2
  • Score
    100M100P100Q30199F
  • License MIT

Best data table for vue.

Package Exports

  • best-vue-table

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (best-vue-table) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

vue-table

Best date table for vue2

How to use?

npm(need to upload to npm)

For now, you can down /dist/vue-table.umd(.min).js

As the name shows, it is a UMD bundle!! So you can import/require or just use script tag!

and use

<vue-table :columns="todoTable.columns" :options="todoTable.options" :source="todoTable.source"></vue-table>
import {vueTable} from './vue-table.umd.min.js'
let app = new Vue({
        el: "#app",
        components: {
            vueTable: vueTable
        },
        data: {
            todoTable: {
                options:{
                  styleType:'semantic', //e.g. semantic bootstrap
                  style:{/*see src/style.js */}
                },
                columns: ["id", {name: "desc",display:'Desc'}, {
                    name: "op", format: function (row) {
                        return '<button>OP</button>';
                    }
                }],
                // Promise mode
                // source:function(params) {
                //   return new Promise.resolve([{id:1,desc:'happy to use vue-table'},{id:2,desc:'happy to use vue-table'}])
                // },
                // Data mode
                source:[{id:1,desc:'happy to use vue-table'},{id:2,desc:'happy to use vue-table'}]
                // Api mode
                // source: {apiUrl: "/data/mock.json", method: "GET"}
            }
        }
    });