You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
カミナシのソフトウェアエンジニア佐藤です。カミナシレポートの開発に携わっています。 フロントエンドのエラーは「画面リロードやブラウザ再起動で復旧できる(かもしれない)」「クラッシュしてもユーザーの端末に閉じる」などの理由から、バックエンドよりは精緻に扱われない傾向があると個人的には感じています。 その一方、カミナシレポートは、ノンデスクワーカー向けの不安定なネットワーク環境で利用されることも多々あるアプリです。そのため、デジタルツールに不慣れな方のために精緻なフィードバックが必要とされる、リロードに頼ることが難しいケースがある、などの理由でエラーの扱いにも慎重になる必要があります。 本記事では、カミナシレポートのフロントエンド開発をする中で、 バックエンドの API コール時にエラーが発生する条件とその内容(型・クラス) これらエラーをハンドリングする箇所 について、把握しておきたいと感じ
Level up your testing skills by learning directly from me! Read more Honestly, I'd never thought I'd be writing about this, but the matter of patching globals turned out to be one of those topics that a lot of engineers seem to misunderstand. Most of us don't do monkey-patching, and even fewer stay around those implementations long enough to witness their impact. All the more reason to talk about
Intro 最近 AbortSignal.any() が提案され、急速に実装が進んでいる。 すでに定義されている AbortSignal.timeout() や addEventListener() への Signal なども含め、非同期処理の中断を実装する際の API はかなり整備されてきた。 これら API のモチベーションと設計を中心にまとめる。 Abort 後のリソース解放 AbortSignal によって、非同期処理のキャンセルが可能になった。例として、Server 上での Fetch のタイムアウトの例を考えよう。 app.get("/entries", async (req, res) => { const perRequestController = new AbortController() const perRequestSignal = perRequestContr
Photo by Brixiv from PexelsIn my previous article, “Deep Insights Into JavaScript’s Fetch API”, I discussed the basics of the Fetch API. But it’s worth acknowledging that fetch() isn’t consistently an ideal solution, and there are sometimes better alternatives for making HTTP requests. Here I’ll describe why Axios is better than fetch() in development. This is my 36th Medium article. Overview and
tldr: AbortController is used to abort a fetch request. Check out this demo. As of today, there are two primary ways to make a request in the browser. XMLHttpRequest and fetch. XMLHttpRequest existed in browsers for a long time. the fetch was introduced with ES6. XMLHttpRequest was always abortable. An abortable XHR request looks something like this. let xhr = new XMLHttpRequest(); xhr.method = 'G
The whatwg-fetch package is now a module with exports. The following methods/classes are available: fetch Headers Request Response DOMException All exports except for DOMException represent the polyfill implementations, not the native variants if they are available. This library still automatically acts like a polyfill if native window.fetch is unavailable; there is currently no way to use it as a
*"If you stream it, you can do it" -- Walt Disney[^1] * Streams are trickling into the scene as we search for ways to improve performance. What if instead of waiting for our entire ajax response to complete, we could start showing the data as it arrives? Streams allow us to do this. They are a data source that can be created and processed incrementally. This means as chunks of data become availabl
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message By setting the keepalive flag, a developer can make a fetch which will continue working even when a frame is detached. A web developer can use the feature to report events, state updates and analytics with small amount of data even when the page is about to be unl
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く