Skip to content

自定义的公共组件Toast,支持多种参数配置

Notifications You must be signed in to change notification settings

xing-zlear/PublicComponent_Toast

Repository files navigation

toast

A Toast project

可配置参数

参数名称 类型 含义 默认值 是否必填
content String 消息提示的内容
type String 提示状态类型,info、success、warning、error 四个选项 info
duration Number 显示时间-毫秒 1500
showClose Boolean 是否显示关闭按钮 不显示
position String 位置信息:left、center、right center
onClose function 关闭toast后的回调函数

Build Setup

# install dependencies
npm install

# serve with hot reload at localhost:8080
npm run dev

# build for production with minification
npm run build

Use

# install
npm install zlear-toast

# import
import Toast from 'zlear-toast'
Vue.use(Toast)

# use
this.$toast({
    content: 'toast的内容'
})

For detailed explanation on how things work, consult the docs for vue-loader.

About

自定义的公共组件Toast,支持多种参数配置

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published