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

@datagetter.cn/area-dragger

v1.2.0

Published

基于Vue的区域拖拽组件

Readme

vue-area-dragger

基于Vue的区域拖拽组件

安装

npm i @datagetter.cn/area-dragger

参数/方法

| 参数/方法 | 描述 | | -- | -- | | imgUrl | 背景图地址 非必填 | | moveWidth | 拖拽区宽 非必填 默认100| | moveHeight | 拖拽区高 非必填 默认100| | wrapWidth | 容器高 非必填 默认200| | wrapHeight | 容器高 非必填 默认200| | getAreaPosition() | 获取区域的位置 | | getZoomRatio() | 获取背景的缩放比例 | | async getImageSize() | 获取图片的尺寸 | | slot[name=content] | vue插槽 | | v-on:areamove | 区域移动时,触发的vue事件 |

使用方法 超简单

<template>
  <div>
      <!-- 可通过imgUrl设置图片 -->
	<AreaDragger
		imgUrl="http://datagetter.cn:9000/datagetter.cn/public/common/datagetter_qrcode.png"
		@areamove="areamove"
		>
        <template slot="content">这里可自定义内容</template>
    </AreaDragger>
  </div>
</template>

<script>
import AreaDragger from '@datagetter.cn/area-dragger/lib/AreaDragger';

export default {
	components: { AreaDragger },
	methods: {
		areamove (areaPos,zoomRatio,imageSize) {
			console.log(areaPos,zoomRatio,imageSize);
		}
	}
}
</script>

二次开发步骤

  • 1.开源地址下载代码 https://github.com/lizhiqianduan/vue-area-dragger

  • 2.进入项目执行命令

npm install && npm run test
  • 3.修改相关代码,即可实时预览效果

最后

如果觉得有用,右上角请留下你的star,这样能让更多的人知道,不胜感激!