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

vue-myplugin-ljt

v0.1.1

Published

一些简单的封装

Readme

基于elementui的二次封装

基于element-ui,需要先安装element-ui并引入样式。
个人学习使用,仅供参考

Project setup

npm i vue-myplugin-ljt

1、输入框

功能

1.绑定值,采用 :value 进行数据的双向绑定 2.必填项,添加 MustInput 属性,则输入框为黄底带必填icon的输入框 3.回车跳下一个 设置 focusNext 属性,绑定要跳转的下一个输入框的ref,即可实现按回车跳转下一个输入框,可自定义跳转顺序

<my-Input focusNext="next" :value="test" MustInput></my-Input>
<my-Input :value="test" MustInput></my-Input>
<my-Input ref="next" focusNext="search" :value="test" MustInput></my-Input>

2、按钮

功能

可以通过@rightClick实现右击事件

3、文本

功能

1.可以通过color、font、bold、align属性直接设置样式 2.可以通过@rightClick实现右击事件

4、自定义指定

(1)聚焦 v-directive

<my-Input v-directive :value="test"></my-Input>

(2) 防抖 v-debounce

防抖指令 单位时间只触发最后一次
@param {Function} fn - 执行事件
@param {?String|"click"} event - 事件类型 例:"click"
@param {?Number|500} time - 间隔时间
@param {Array} binding.value - [fn,event,time]
直接使用: <XXX v-debounce="reset]">刷新</XXX>
配置事件,间隔时间: <button v-debounce="[reset,'click',500]">刷新</button>
事件传递参数则: <button v-debounce="[()=>reset(param),`click`,500]">刷新</button>

(3) 节流 v-throttle

节流指令 一段时间内首次触发时立即执行,此时间段内再次触发,不会执行!
@param {Function} fn - 执行事件
@param {?String|"click"} event - 事件类型 例:"click"
@param {?Number|500} time - 间隔时间
@param {Array} binding.value - [fn,event,time]
直接使用: <XXX v-throttle="reset]">刷新</XXX>
配置事件,间隔时间: <button v-throttle="[reset,'click',500]">刷新</button>
事件传递参数则: <button v-throttle="[()=>reset(param),`click`,500]">刷新</button>

(4) 添加水印 v-waterMarker

可以设置text、font、textColor
<div style="width: 100px; height: 100px;border: 1px solid #ccc;position: relative;" v-waterMarker="{text: '测试', textColor: 'pink'}"></div>