npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@springleo/el-table-plus

v1.0.0

Published

## Install

Downloads

11

Readme

el-table-plus

Install

yarn add @springleo/el-table-plus

Online Example

https://lq782655835.github.io/el-table-plus

Quick Start

Import modules and set up settings in main.js:

import ElTablePlus from '@springleo/el-table-plus'
Vue.use(ElTablePlus)

use <el-table-plus> in your page

<template>
    <el-table-plus
      :data="list"
      :columns="[
        { label: 'ID', value: 'id', width: '80px' },
        { label: '存储卷名', value: 'name' },
        { label: '总容量', value: 'storage', fn: val => `${val}G` },
        { label: '创建人', value: 'member.userId' },
        { label: '邮箱', value: 'member.email' },
        { label: '创建时间', value: 'gmtCreate' }
      ]"
    />
</template>

API

el-table-plus 属性

支持el-table上所有原有属性,同时扩展以下api。

参数 | 类型 | 默认值 | 说明 --- | --- | --- | --- loading | Boolean | false | 动效loading data | Array | [] | 列表数据 columns | Array | [] | column item配置列表,详细见如下columns Attrs pagination | Object | | 翻页器配置,默认未设置,不显示翻页器。相关api可查看el-pagination total | Number | 0 | 翻页器条数总数

el-table-plus 事件

支持el-table上所有原有事件,同时扩展以下api。

事件名称 | 说明 | Description --- | --- | --- scroll | table滚动条事件 | e page-change | 翻页器改变事件 | { pageSize, currentPage }

columns 属性

支持el-table-column所有原有属性Scoped Slot,同时扩展以下api:

Attr | Type | Default | Description --- | --- | --- | --- label | String | | 列名称 prop | String | | 列数据字段,支持多层对象嵌套,如user.email.prefix fn | Function | | 格式化列。函数参数(value, row, column, $index) hidden | Boolean | | 是否隐藏该列。建议是一个computed,使得可以响应式显示隐藏 customRender | Function | | 自定义列数据渲染。函数参数(value, row, column, $index, h),支持jsx和h函数 customTitle | Function | | 自定义列头部渲染。函数参数(column, $index, h),支持jsx和h函数 scopedSlots | Object | | 使用slot方式自定义渲染,替换customRender/customTitle函数。比如:{ customRender: 'slotName1', customTitle: 'slotName2' }

License

MIT