var vue = new Vue({ el: '#dip_main_div', data () { return { title: "Public IP Address service", dip: {"ip": null, "hostname": null, "city": null, "country": null}, } }, mounted () { axios.get("https://ip.paulbsd.com") .then(response => { this.dip = response.data }) .catch(err => { // Manage the state of the application if the request // has failed }); } });