<script>
  import promisifyAll from './lib/wx-promise-pro/index';
  import config from './config/index';
  import server from './utils/server';
  import api from './api/index';
  import util from './utils/util';
  import upload from './utils/upload';
  import './utils/share';
  // 日志调试模式
  if (config.debug) {
    // eslint-disable-next-line no-console
    console.log('小程序配置:', config);
    // eslint-disable-next-line no-console
    // console.log('微信全局配置:', __wxConfig);
  }

  // 微信API支持Promise风格
  promisifyAll();
  export default {
    globalData:{
      config,
      env: config.env,
      api,
      util,
      userId: uni.getStorageSync('userInfoData').userId,
      login: server.login,
      register: server.register,
      upload
    },
    data() {
      return {
        
      };
    },

  };
</script>
<style lang="less">
  @import 'style/theme.less';
  @import 'style/normalize.less';
  @import 'style/public.less';
</style>