圖一 chrome devtools - Network

平時在除錯前端頁面時,與後端的互動基本都通過 ajax,所以除錯起來會經常用到 Network 裡面的 XHR,有時候因為請求介面會比較多,如果可以僅僅過濾出我們想看的那一個介面,那麼除錯起來會便利很多
福利來了
Chrome 開發者工具 Network 登場

如果此時我只想看 IsMyFavorites 這個介面呢 可以是使用這樣語法 -method:OPTIONS ismy -method:OPTIONS 表示請求的方法為 OPTIONS 的介面不顯示,這是因為跨域呼叫介面時,會額外傳送一個 OPTIONS 介面

可以自行嘗試對比篩選 -mehtod:OPTIONS ismy ismy 兩個的區別 :)
ps 此功能需要高版本 chrome,是時候升級你的 chrome 了
