import Vue from 'vue' import App from './App' //import mqtt from 'mqtt/dist/mqtt.js' import store from './store' Vue.prototype.$store = store Vue.config.productionTip = false App.mpType = 'app' // const options = { // connectTimeout: 4000, // 超时时间 // clientId: "mqtt_" + parseInt(Math.random() * 100 + 800, 10), // port: 8081, // }; // const store = { // debug: true, // mqttClient:undefined, // connect(){ // this.mqttClient = mqtt.connect('wxs://test.mosquitto.org', options) // let that = this; // //连接成功回调 // that.mqttClient.on("connect", function() { // that.isConnect = true; // console.log("connect success!"); // }); // //异常回调 // that.mqttClient.on("error", function(err) { // that.isConnect = false; // console.log(err); // }); // } // } const app = new Vue({ store:store, ...App }) app.$mount()