App.vue 884 B

1234567891011121314151617181920212223242526
  1. <script>
  2. export default {
  3. onLaunch: function() {
  4. console.log('App Launch')
  5. uni.toast = (...args) => uni.showToast({ duration: 5678, title: args[0], icon: 'none' })
  6. uni.loading = () => uni.showLoading({ mask: false })
  7. },
  8. onShow: function() {
  9. console.log('App Show')
  10. },
  11. onHide: function() {
  12. console.log('App Hide')
  13. }
  14. }
  15. </script>
  16. <style lang="scss">
  17. @import 'common/style/main.scss'; //引入 ColorUI 组件库主样式
  18. @import 'common/style/icon.scss'; //引入 ColorUI 组件库图标样式
  19. @import 'common/style/animation.scss'; //引入 ColorUI 组件库动画样式
  20. page { //uniapp 中的 page 标签相当于 html 中的 body, 默认高度为 auto, 但是高度为 100% 更利于 app 布局,你也可以在 page 中设置一些全局样式,比如全局背景色
  21. height: 100%;
  22. background: #FFFFFF;
  23. color: $app-main-text-color;
  24. }
  25. </style>