mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
chore: avoid using delete (#4923)
This commit is contained in:
parent
56e9b7afa0
commit
fbb34a0f90
@ -84,7 +84,7 @@ function Search(
|
|||||||
};
|
};
|
||||||
|
|
||||||
const inheritData = inherit(ctx);
|
const inheritData = inherit(ctx);
|
||||||
delete inheritData.attrs;
|
inheritData.attrs = undefined;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
|
@ -62,13 +62,12 @@ function createInstance() {
|
|||||||
|
|
||||||
// transform toast options to popup props
|
// transform toast options to popup props
|
||||||
function transformOptions(options) {
|
function transformOptions(options) {
|
||||||
options = { ...options };
|
return {
|
||||||
options.overlay = options.mask;
|
...options,
|
||||||
|
overlay: options.mask,
|
||||||
delete options.mask;
|
mask: undefined,
|
||||||
delete options.duration;
|
duration: undefined
|
||||||
|
};
|
||||||
return options;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function Toast(options = {}) {
|
function Toast(options = {}) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user