| | |
| | | import uviewPlus, { setConfig } from "uview-plus" |
| | | import uviewPlus, { |
| | | setConfig |
| | | } from "uview-plus" |
| | | |
| | | function setupUI(app) { |
| | | // 下面的在特殊场景下才需要配置,通常不用配置即可直接使用uview-plus框架。 |
| | |
| | | // 修改$u.config对象的属性 |
| | | config: { |
| | | // 修改默认单位为rpx,相当于执行 uni.$u.config.unit = 'rpx' |
| | | unit: "px" |
| | | unit: "rpx" |
| | | }, |
| | | // 修改$u.props对象的属性 |
| | | props: { |
| | |
| | | } |
| | | }) |
| | | |
| | | app.use(uviewPlus) |
| | | app.use(uviewPlus, () => { |
| | | return { |
| | | options: { |
| | | // 修改config对象的属性 |
| | | config: { |
| | | customIcon: { |
| | | family: 'xyicon', |
| | | url: 'https://at.alicdn.com/t/c/font_5036193_7g86rzw8srl.ttf?t=1760003919145' |
| | | }, |
| | | customIcons: { |
| | | 'tuceng': '\uea2d', |
| | | 'dingwei': '\ue610', |
| | | }, |
| | | } |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | |
| | | export default setupUI |