mirror of
https://github.com/youzan/vant.git
synced 2025-10-21 11:17:41 +00:00
fix(Icon): add info prop deprecation warning (#7347)
* fix(Icon): add info prop deprecation warning * chore: adjust
This commit is contained in:
@@ -50,6 +50,12 @@ function Icon(
|
||||
const name = correctName(props.name);
|
||||
const imageIcon = isImage(name);
|
||||
|
||||
if (process.env.NODE_ENV !== 'production' && props.info) {
|
||||
console.warn(
|
||||
'[Vant] Icon: "info" prop is deprecated, use "badge" prop instead.'
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
<props.tag
|
||||
class={[
|
||||
|
Reference in New Issue
Block a user