当前位置:首页 > 编程笔记 > 正文
已解决

Request failed with status code 422

来自网友在路上 157857提问 提问时间:2023-09-22 16:24:20阅读次数: 57

最佳答案 问答题库578位专家为你答疑解惑

尚硅谷vue技术学习过程中遇到的问题等待解决

在这里插入图片描述
在这里插入图片描述

<template><section class="jumbotron"><h3 class="jumbotron-heading">Search Github Users</h3><div><input type="text" placeholder="enter the name you search"/>&nbsp;<button @click="searchUsers">Search</button></div></section>
</template><script>
import axios from 'axios'
export default {name:'Search',data() {return {keyWord:''}},methods: {searchUsers(){axios.get(`https://api.github.com/search/users?q=${this.keyWord}`).then(response => {console.log('请求成功了',response.data)},error => {console.log('请求失败了',error.message)})}},
}
</script><style></style>
查看全文

99%的人还看了

猜你感兴趣

版权申明

本文"Request failed with status code 422":http://eshow365.cn/6-11527-0.html 内容来自互联网,请自行判断内容的正确性。如有侵权请联系我们,立即删除!