From 296e81af4d26050f9b45fab1291f533e76e4dc2d Mon Sep 17 00:00:00 2001 From: Tan Li Hau Date: Tue, 29 Sep 2020 22:58:00 +0800 Subject: [PATCH] add EventSource to the known globals (#5468) --- CHANGELOG.md | 4 ++++ src/compiler/utils/names.ts | 1 + 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a557769607..b0c5414f11 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Svelte changelog +## Unreleased + +* Add `EventSource` to known globals ([#5463](https://github.com/sveltejs/svelte/issues/5463)) + ## 3.28.0 * Add `{#key}` block for keying arbitrary content on an expression ([#1469](https://github.com/sveltejs/svelte/issues/1469)) diff --git a/src/compiler/utils/names.ts b/src/compiler/utils/names.ts index 1fa37660f4..7b6a6f55e0 100644 --- a/src/compiler/utils/names.ts +++ b/src/compiler/utils/names.ts @@ -18,6 +18,7 @@ export const globals = new Set([ 'Error', 'EvalError', 'Event', + 'EventSource', 'fetch', 'global', 'globalThis',