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

vi-count-down

v1.0.3

Published

微信小程序倒计时组件

Downloads

4

Readme

倒计时组件文档

使用

在使用之前,请先用微信开发者工具构建NPM和使用NPM模块

打开小程序页面的json配置.

"usingComponents": {
  "count-down": "vi-count-down" 
}

使用字符串形式的日期格式

<count-down endTime="2018/12/01></count-down>

使用毫秒数的日期格式

<count-down end-time="{{1543593600000}}"></count-down>

属性

| 接口 | 数据类型 | 说明 | 选项 | 默认值 | | :--: | :--: | :--: | :--: | :--: | | endTime | String, Number | 接收字符串形式的时间格式或者毫秒数 | 必填 | null | | startTime | String,Number | 接收字符串形式的时间格式或者毫秒数 | 选填 | null | | endText | String | 接收字符串文本 | 选填 | 该订单已超过支付时间 | | isSlot | Boolean | 用于构建自定义DOM接口,该接口与countdown事件配合使用| 选填 | false |

event 事件

| event name | 说明 | 返回值说明 | | :--: | :--: | :--: | :--: | :--: | | countdown | 用于自定义倒计时组件的DOM结构,这方法适用于复杂的倒计时UI,注意和isSlot接口配合使用,不然无法覆盖DOM结构 | Object |

版本记录

  • v1.0.3 新增自定义事件countdown和接口isSlot

Bug&Tips

  • 组件是向上兼容,如果小程序版本库低于2.0.1 该组件库的 clearTimeout将会失效