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

coopwire-plugin-screenshot2

v0.1.30

Published

为 Logwire 和 Coopwire 开发的全局反馈插件

Downloads

9

Readme

coopwire-plugin-screenshot

为 Logwire 和 Coopwire 开发的全局反馈插件

Usage

通过 webpack 使用

npm install coopwire-plugin-screenshot --save

代码

// main.js
import Screenshot from 'coopwire-plugin-screenshot'  
Vue.use(Screenshot, options) // 此时注册了一个名称为 toolbar 的组件到系统内

// App.vue
<template>
  <toolbar>
</template>

参数内容

Options 参数内容

|参数名称|类型|说明| |-|-|-| |ElementUI|-|Element UI框架,为了节约打包空间,框架使用系统引入的,在项目内通过 import 引入 ElementUI 后,还需要在此处传递给插件| |Axios|-|Axios 实例,可以是 axios 框架导出的内容,也可以是系统内对 axios 实例定制化后的实例,保持和系统内接口调用的 axios 一致| |getProjectInformation|InformationOptions|获取项目信息参数|

InformationOptions 参数内容

|参数名称|类型|说明| |-|-|-| |getProjectId|Function|如何获取当前打开的的项目ID,创建成功后反馈将出现在此项目内,不设置则返回空字符串| |getProjectName|Function|如何获取当前打开的项目名称, 请做好异常处理,不设置则返回空字符串| |getRequestRoot|Function|如何获取请求根路径,在 Logwire 中使用时,请求地址是 Coopwire 接口地址,需要更改根路径,不设置则返回空字符串| |getUserEmail|Function|如何获取当前用户邮箱,不设置则返回空字符串| |checkHelp|Function|点击帮助按钮时触发逻辑,不同系统内可以跳转不同地址|

所有方法内 this 参数都可以获取到当前系统的 $store, $router 等内容,因为方法最终调用时会作为混入内容处理,所以请不要写箭头函数

更新

代码会提交到 gitlab 仓库, 开发者可以下载后更改其中内容
然后执行下列命令

npm version 命令创建一个新的版本号
npm run build 根据当前版本号打包内容
在使用插件的地方进行版本号的更新