Get to know MDN better
このページはコミュニティーの尽力で英語から翻訳されました。MDN Web Docs コミュニティーについてもっと知り、仲間になるにはこちらから。
This feature is well established and works across many devices and browser versions. It’s been available across browsers since 2020年1月.
メモ: この機能はウェブワーカー内で利用可能です。
EventSource() コンストラクターは、リモートリソースを表す新しく作成された EventSource を返します。
文字列で、イベント/メッセージを処理するリモートリソースの場所を表します。
options 省略可新しいコネクションを構成するオプションを提供します。可能な項目は次のとおりです。
withCredentials 省略可論理値で、既定値は false であり、 CORS の資格情報を include に設定すべきかどうかを示します。
メモ: 完全な例は GitHub で見られます。 PHP を用いた簡単な SSE のデモ を参照してください。
| HTML # dom-eventsource-dev |
Enable JavaScript to view this browser compatibility table.
This page was last modified on 2026年3月16日 by MDN contributors.
Your blueprint for a better internet.
Visit Mozilla Corporation’s not-for-profit parent, the Mozilla Foundation.
Portions of this content are ©1998–2026 by individual mozilla.org contributors. Content available under a Creative Commons license.