Skip to content

Instantly share code, notes, and snippets.

@slim-python
Created August 20, 2020 21:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save slim-python/7dffe33a19b6fda184c4fc09d05b428a to your computer and use it in GitHub Desktop.
Save slim-python/7dffe33a19b6fda184c4fc09d05b428a to your computer and use it in GitHub Desktop.
Vue Js part
<script>
new Vue({
el: '#app',
data: {
info: 'null',
author: 'null'
},
methods: {
},
mounted() {
axios
.get('http://quotes.rest/qod.json?category=inspire')
.then(response => {
this.info = response.data.contents.quotes[0].quote
this.author = response.data.contents.quotes[0].author
})
}
})
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment