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 🙏

© 2025 – Pkg Stats / Ryan Hefner

cbwclient

v0.2.20

Published

cbw wallet connect client

Downloads

56

Readme

cbwclient

使用流程

app 接入

  • 从 cbw 申请租户,获取到 tenantKey
  • 导入 SDK, 初始化配置,设置 tenantKey
  • 在使用转账等功能时调用 SDK 的方法即可

用户使用

  • 用户连接钱包时,选择CBW,否则弹出用户自己安装的钱包列表
  • 用户输入手机号登录/注册,创建钱包
  • 然后授权钱包,后续确认是否允许转账等操作

技术体系

  • 最终生成 vue 组件,在 uniapp 或者其他 vue项目中可直接引用的方式
  • 发布到 npm

发布

npm run lib

npm login

npm publish

Project setup

yarn add cbwclient

出现错误时:

unable to access 'https://github.com/ethereumjs/ethereumjs-abi.git/': Failed to connect to github.com port 443: Timed out

即网络问题,可以使用代理方式下载, 如

yarn config set proxy http://127.0.0.1:7890

完成后还原

yarn config delete proxy

How to use

// main.js
import cbwclient from 'cbwclient'
// 内部使用了 IViewUI 的组件
import 'view-design/dist/styles/iview.css'

Vue.use(cbwclient);
    function showWallet() {
      this.$connBtn.show()
      this.$connBtn.init({
         tenantKey: 'rOPTYYRwvxlEVZaf9mzkk',
         bridge: 'http://localhost:9060',
         infuraId: '3a605cb9422947458b71fecdcf1ac2ab',
         env: 'ropsten'
      })
      this.$connBtn.open()
    }
    function hideWallet() {
      this.$connBtn.hide()
    }
    function transfer() {
      let orderId = 'SXQ12397bk'
      this.$connBtn.transfer(orderId, this.symbol, this.address, this.amount).then(res => {
        console.log('转账成功', res)
      }).catch(err => {
        console.log('转账失败', err)
      })
    }

env 可选值:

  • 'ropsten'
  • 'mainnet'