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

react-virtuallist-an

v0.0.9-alpha.0

Published

Now I’m the model of a modern major general / The venerated Virginian veteran whose men are all / Lining up, to put me up on a pedestal / Writin’ letters to relatives / Embellishin’ my elegance and eloquence / But the elephant is in the room / The truth i

Downloads

4

Readme

根据业务需求封装的高性能 React 表格组件

参考 ali-react-table

安装

npm i react-virtuallist-an

特点

高性能,内置虚拟滚动,数据量较大时自动开启

简单灵活的 API,丰富的定制能力

实用的表格特性:表头吸顶 & 左侧/右侧锁列 & 粘性定位的滚动条

表格适用场景

需要用表格展示大量数据,对表格性能较为敏感

页面没有引入 React 组件库,需要一个尺寸较小的表格组件

原有表格组件可定制能力不够,需要更加灵活的表格组件

虚拟滚动

通过 dataSource 传入一个长度超过 5 万的数组,表格依旧流畅。当表格向下滚动时,BaseTable 默认会为表头设置 style.position=sticky,表头将会吸附在页面或滚动容器的顶部

留存矩阵与投入产出分析表格

BaseTable 提供了灵活且丰富的 API,方便上层根据各类业务需求对表格进行定制,定制的内容包括单元格内容与样式、鼠标事件回调等。

优化的加载图标位置

优化的加载图标位置,加载图标会位于表格的中心位置,并始终处于可见状态。

简单透视表格基于 BaseTable 的简单透视表格。一般来说,透视表展示的数据量较大,不过 BaseTable 内置的虚拟滚动保证了表格在大数据量下仍具有很好的性能,上层不需要过多担心性能问题。

兼容性说明

表格只兼容 react ^16.8.0 || ^17.0.0。

此外表格用到了大量较新的浏览器 API,只兼容较新版本的 PC 端浏览器或手机浏览器