import Vue from 'vue'; import lib from 'lib'; export default{ data () { return { user_id : lib.getLocalData("user_id"), game_zone : lib.getLocalData("game_zone") } }, mounted () { this.getData(); }, beforeDestroy () { }, methods: { getData () { let self = this; let api = `${lib.apiUrl}/player/${self.game_zone}/${self.user_id}/`; let data = {}; lib.get(api, (ret) => { console.log(ret); }) } } }