mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-23 18:00:27 +08:00
fix(SwitchCell): add deprecation warning (#7350)
This commit is contained in:
parent
b4f2f2f330
commit
3fc2af9842
@ -30,6 +30,12 @@ function SwitchCell(
|
|||||||
slots: DefaultSlots,
|
slots: DefaultSlots,
|
||||||
ctx: RenderContext<SwitchCellProps>
|
ctx: RenderContext<SwitchCellProps>
|
||||||
) {
|
) {
|
||||||
|
if (process.env.NODE_ENV !== 'production') {
|
||||||
|
console.warn(
|
||||||
|
'[Vant] "SwitchCell" component is deprecated, see: https://youzan.github.io/vant/#/zh-CN/switch-cell.'
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Cell
|
<Cell
|
||||||
center
|
center
|
||||||
|
Loading…
x
Reference in New Issue
Block a user