mirror of
https://github.com/youzan/vant.git
synced 2025-10-22 11:54:02 +00:00
[improvement] Info: jsx (#2529)
This commit is contained in:
13
packages/info/index.js
Normal file
13
packages/info/index.js
Normal file
@@ -0,0 +1,13 @@
|
||||
import { use, isDef } from '../utils';
|
||||
|
||||
const [sfc, bem] = use('info');
|
||||
|
||||
export default sfc({
|
||||
props: {
|
||||
info: [String, Number]
|
||||
},
|
||||
|
||||
render(h) {
|
||||
return isDef(this.info) && <div class={bem()}>{this.info}</div>;
|
||||
}
|
||||
});
|
Reference in New Issue
Block a user