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 🙏

© 2026 – Pkg Stats / Ryan Hefner

agel-table

v0.3.80

Published

a easy table of element-ui table

Readme

agel-table

npm version npm downloads license

基于 Vue 2 和 Element UI 2 的表格封装。将表格数据、列、查询、分页和扩展行为集中在一个配置对象中,同时保留 Element UI 表格的常用属性、事件和实例方法。

适合已有 Vue 2 + Element UI 项目,需要复用表格配置、服务端分页、操作列、单元格合并、容器高度适配或固定行高虚拟滚动的场景。

主要能力

  • 使用一个响应式对象声明表格数据和列配置。
  • 通过 request(query, done, fail) 接入服务端数据、排序和分页。
  • 支持嵌套列、自定义单元格/表头插槽、动态列显隐和操作列。
  • 可配置纵向或横向相同值合并,以及随容器尺寸变化的表格高度。
  • 固定行高虚拟滚动支持大数据列表,并保留 Element UI 的表格、列和复选框渲染。

虚拟模式需要固定行高;树形数据、表格筛选、行展开、单元格合并和可变行高不属于虚拟滚动支持范围。完整说明见使用指南和 API 参考。

环境要求

  • Vue 2
  • Element UI 2

本库使用宿主项目已安装的 Vue 与 Element UI,不会替项目注册 Element UI 样式。Vue 3 项目请使用 element-plus-crx。

安装

npm install agel-table

快速开始

在应用入口注册 Element UI 和 agel-table:

import Vue from 'vue'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import agelTable from 'agel-table'

Vue.use(ElementUI)
Vue.use(agelTable, {
  table: {
    border: true
  }
})

在页面中通过一个对象配置表格:

<template>
  <agel-table v-model="table" />
</template>

<script>
export default {
  data() {
    return {
      table: {
        height: 320,
        columns: [
          { prop: 'name', label: '姓名', minWidth: 120 },
          { prop: 'status', label: '状态', width: 100 }
        ],
        data: [
          { name: '张三', status: '正常' },
          { name: '李四', status: '待处理' }
        ]
      }
    }
  }
}
</script>

配置说明、服务端分页和虚拟滚动示例见使用指南;选项、事件与方法见 API 参考。

文档与变更

许可证

MIT