Skip to content

Latest commit

 

History

History
20 lines (20 loc) · 584 Bytes

README.md

File metadata and controls

20 lines (20 loc) · 584 Bytes

VueAxios

Using APIs with Vue js and Axios
Check if you have the node js installed on your machine node --version
If you have not https://nodejs.org/en/
To use db.json you need an json server npm install -g json-server
Then run the command json-server file_name.json

const vue = new Vue({
  el:"#root",
  data:{
    infor:null
   },
   mounted(){
     axios
      .get(['Coloque aqui sua url'])
      .then(response => { this.info = response })
      .catch(error => { console.log(error) })
    }
});