You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
379 B
14 lines
379 B
import isObject from './isObject';
|
|
|
|
/**
|
|
* @description: 快捷提示
|
|
* @param {String|object} options 提示文案或对象参数
|
|
* @param {Number} duration 默认 1500 ms
|
|
*/
|
|
export default function showToast(options, duration = 1500) {
|
|
uni.showToast(Object.assign({
|
|
title: '',
|
|
icon: 'none',
|
|
duration,
|
|
}, isObject(options) ? options : { title: options }));
|
|
}
|
|
|