1.1.6 • Published 5 years ago

vue-table-helper v1.1.6

Weekly downloads
-
License
MIT
Repository
github
Last release
5 years ago

vue-table-helper

NPM

npm GitHub license

A wrapper for the <b-table> component of BootstrapVue. Adds pagination, column selection, research input, full screen mode and CSV export.

Prerequisites

You need to have installed Bootstrap 4 and BootstrapVue:

npm install --save bootstrap bootstrap-vue

Installation

npm install --save vue-table-helper

Usage

Import the component and register globally

import VueTablehelper from 'vue-table-helper'
import 'vue-table-helper/dist/vue-table-helper.css'

Vue.use(VueTablehelper);

Example of use

<template>
    <div id="app">
        <vue-table-helper :fields="fields" :items="items">
        </vue-table-helper>
    </div>
</template>

<script>
    import VueTablehelper from 'vue-table-helper'
    import 'vue-table-helper/dist/vue-table-helper.css'

    Vue.use(VueTablehelper);

    export default {
        name: 'app',
        data() {
            return {
                items: [
                    {id: 0, first_name: 'John', last_name: 'Doe', age: 40},
                    {id: 0, first_name: 'Adam', last_name: 'Smith', age: 40},
                    {id: 0, first_name: 'Stan', last_name: 'Lee', age: 10}
                ],
                fields: [
                    {key: 'id', label: 'ID', sortable: true, hidden: true},
                    {key: 'first_name', label: 'First name', sortable: false},
                    {key: 'last_name', label: 'Last name', sortable: true},
                    {key: 'age', label: 'Age', sortable: true}
                ]
            }
        }
    }
</script>
1.1.6

5 years ago

1.1.5

5 years ago

1.1.4

5 years ago

1.1.3

5 years ago

1.1.2

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago