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

@hiwx/input

v0.0.1

Published

--- module: '基础' title: '文本框' ---

Readme


module: '基础' title: '文本框'

文本框组件

使用效果

安装方法

1、设置npm的源地址

sudo npm config set registry http://registry.npm.yangtuojia.com

2、安装

npm install @yt/wx-input --save

3、微信开发者工具---》工具---构建npm

使用方法

   <view class="mb-24">
      <view>
          <comp placeholder="请输入姓名" bindinputevent="iptVal"></comp>
          <comp placeholder="请输入密码"></comp>
      </view>
  
      <view class="mb-24">
          <comp label="姓名"></comp>
          <comp label="密码"></comp>
      </view>
  
      <view class="p-24">
          <comp placeholder="请输入姓名" bindinputevent="iptVal" wrapCls="card mb-24" name="pName"></comp>
          <comp placeholder="请输入密码" wrapCls="card mb-24"></comp>
      </view>
  
      <view class="p-24">
              <comp label="法人身份证号码" wrapCls="card mb-24" require="{{true}}" name="phone"></comp>
              <comp label="密码" wrapCls="card"></comp>
          </view>
   </view>

index.js
Page({
    iptVal(e) {
        console.log(e);
    }
})

api说明

| 属性名 | 类型 | 默认值 | 是否必须 | 说明 | |------------------------|-------------|------------|----------------|---------------------------------------------------| | wrapCls | String | '' | 否 | 最外层容器样式| | require | Boolean | false | 否 | 是否必填,控制是否显示*| | placeholder | String | '' | 否 | placeholder 内容 | label | String | | 否 | 左侧标题 | | value | String | | | 文本框value | type | String | 'text' |否 |input 的类型 text 文本输 入键盘 number 数字输入键盘 idcard 身份证输入键盘 digit 带小数点的数字键盘 textarea 多行输入框 | maxlength | Number | 140 | 否 | 最长字符 | disabled | Booleanfalse 可否输入 | placeholder-class | String | '' | 否 |placeholder样式 | class | String | '' | 否 |文本框样式 | bindinputevent | Function | '' | 否 |键盘输入时触发 | bindinputfocus | Function | '' | 否 |输入框聚焦时触发 | bindinputblur | Function | '' | 否 |输入框失去焦点时触发 | bindinputconfirm | Function | '' | 否 | 点击完成按钮时触发