今天又学了一招在Chrome developer tool中通过Fetch_API发起HTTP请求。 代码示例:
fetch('https://jsonplaceholder.typicode.com/posts/1')
.then(response => response.json())
.then(json => console.log(json))
今天又学了一招在Chrome developer tool中通过Fetch_API发起HTTP请求。 代码示例:
fetch('https://jsonplaceholder.typicode.com/posts/1')
.then(response => response.json())
.then(json => console.log(json))