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

y-scrollbar

v0.1.9

Published

erhai 前端组件库

Downloads

0

Readme

@weier/w-scrollbar

  • 滚动条容器
// 安装
npm i @weier/w-scrollbar -S

// 代码引入(可选)
import Vue from 'vue'
import WScrollbar from '@weier/w-scrollbar'
Vue.use(WScrollbar)

基础用法

容器外的宽高需已知(可滚动即可) noresize 如果 container 尺寸不会发生变化,最好设置它可以优化性能

:::demo

import { defineComponent } from '@vue/composition-api'
import WScrollbar from '@weier/w-scrollbar'

export default defineComponent({
  setup() {

  },
  render() {
    const n = []
    for (let i = 0; i < 100; i++) {
      n.push(i)
    }
    return (
       <div class="WScrollbar-father" style={{
        height: '200px',
        border: '1px dashed #dedede'
       }}>
        <WScrollbar autoShow={false}>
          <ul class="content" style="width: 120%">
            {
              n.map(index => <li key={index}>{index}</li>)
            }
          </ul>
        </WScrollbar>
      </div>
    )
  }
})

:::

w-scrollbar Attributes

| 参数 | 说明 | 类型 | 可选值 | 默认值 | | ---- | ---- | --------- | ---------- | ------- | | zIndex | 滚动条层级 | Number | —— | 1 |
| autoShow | 是否移入时显示 | Boolean | true/false | true | | light | 滚动条的颜色是否亮色 | Boolean | true/false | false | | noresize | 如果 container 尺寸不会发生变化,最好设置它可以优化性能 | Boolean | true/false | false |

w-scrollbar Events

| 事件名称 | 说明 | 参数 | | ---- | ---- | --------- | | reach-top | 到达顶部 | 无 | | reach-bottom | 到达底部 | 无 | | reach-left | 到达最左边 | 无 | | reach-right | 到达最右边 | 无 | | scroll | 鼠标滚动时触发 | scrollInfo(Object) |

scrollInfo 参数

| 参数 | 说明 | 类型 | | ---- | ---- | --------- | | scrollTop | 当前滚动容器的scrollTop | Number | | scrollLeft | 当前滚动容器的scrollLeft | Number |

w-scrollbar Methods

| 方法名 | 说明 | 参数 | | ---- | ---- | --------- | | scrollTo | 滚动容器至-位置 | scrollTop(top/bottom/left/right/end/(Number)), scrollLeft(Number)(可选) |

w-scrollbar-slot

| 参数 | 说明 | 类型 | 可选值 | 默认值 | | ---- | ---- | --------- | ---------- | ------- | | 默认值 | 默认内容 | —— | —— | —— |