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

dora-plugin-backup

v1.0.5

Published

- 功能

Downloads

11

Readme

dora-plugin-backup

  • 功能

将线上数据拉到本地备份 备注: 拉取数据时不用在意 上方的require('mockjs')等,不会覆盖其他已有规则。

  • 安装方式
npm i dora-plugin-backup --save-dev 

1.参数

  • file参数 指定要保存的文件
  • filter参数(正则格式) 用于筛选需要保留的链接
  • attachPort参数(默认proxy插件接口,可不配置) 监听端口后,用于代理时拉取数据接口,没有代理端口8989,需额外代理到路径上,确保不用跨域访问。
a.作为dora-plugin参数传入
  • 1.以config方式配置

  • 2.以inline方式配置(注意&符号在shell中的解析)

b.定制属于自己的规则(推荐)默认级别最高
  • 将backup.config.json加入.gitignore黑名单

注意

  • 1.调试时,避免切换浏览器,切换浏览器请重新启动服务器,socket之间的通信没断开,update协议会对新的浏览器客户端产生影响,此处只做简单处理
  • 2.返回数据确保能解析,部分数据,乱码会导致js解析错误,会重新生成js,内容会重置。最好备份的数据加入到.gitignore避免影响他人。

开发

  • 代理时自动将代理数据拉置本地

  • 安装依赖

tnpm i
  • 发布
tnpm run build
npm publish
  • 测试
tnpm run test
  • 业务效果
cd test/fixtures/ && tnpm i
tnpm start