# Countdown 倒计时 - 图1 Wuss-weapp

首页

组件库

快速上手

GitHub

首页

组件库

快速上手

GitHub

基础组件

  • 布局

  • 导航

  • 操作反馈

  • 表单

  • 其他

# Countdown 倒计时

# 使用指南

在 page.json 中引入组件

  1. "usingComponents": {
  2. "w-countdown": "wuss-weapp/w-countdown/index",
  3. }

# 图片演示

# Countdown 倒计时 - 图2

# 代码演示

<!--pages/w-countdown/index.wxml-->
<w-pane title="Countdown" desc="倒计时" />

<w-pane desc="Default" />
<w-countdown time="{{ date1 }}" />



<w-pane desc="notimestamp = true time = 60" />
<w-countdown time="60" bindcallback="countdownComplate"notimestamp="{{true}}" />

<w-pane desc="format = D" />
<w-countdown time="{{ date1 }}" format="D" />

<w-pane desc="format = H" />
<w-countdown time="{{ date1 }}" format="H" />

<w-pane desc="format = MM" />
<w-countdown time="{{ date1 }}" format="MM" />

<w-pane desc="format = s" />
<w-countdown time="{{ date1 }}" format="s" />

# API

# Attribute 属性

属性 说明 类型 默认值
notimestamp 是否使用时间戳 true 为不是 boolean false
format 格式化时间格式默认为 H string -
time 倒计时的时间单位 s number -

# Event 事件

事件名 说明 参数
callback 倒计时结束回调 ——

# Slot 插槽

名称 说明

# Class 自定义类名

类名 说明
wuss-class 根节点样式类

Edit this page

Steps 步骤条 Badge 徽章