常用基礎配置
// axios的常用預設配置
axios.defaults.method = 'GET';
axios.defaults.baseURL = 'http://localhost:3000';
axios.defaults.params = {id: 2};
btns[0].onclick = function() {
axios({
url: '/posts'
}).then(response => {console.log(response);})
}