Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: sveltejs/svelte
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: svelte@5.25.0
Choose a base ref
...
head repository: sveltejs/svelte
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: svelte@5.25.1
Choose a head ref
  • 4 commits
  • 4 files changed
  • 4 contributors

Commits on Mar 21, 2025

  1. fix docs

    Rich-Harris committed Mar 21, 2025
    Copy the full SHA
    441108b View commit details
  2. doh

    Rich-Harris committed Mar 21, 2025
    Copy the full SHA
    ef98cca View commit details
  3. fix: allow get_proxied_value to return original value when error (#15577

    )
    
    * fix: allow get_proxied_value to return original value when error
    
    closes #15546
    
    * Update packages/svelte/src/internal/client/proxy.js
    
    ---------
    
    Co-authored-by: Rich Harris <hello@rich-harris.dev>
    crookedneighbor and Rich-Harris authored Mar 21, 2025
    Copy the full SHA
    d1bd32e View commit details
  4. Version Packages (#15580)

    Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
    github-actions[bot] authored Mar 21, 2025
    Copy the full SHA
    c1ae895 View commit details
Showing with 20 additions and 4 deletions.
  1. +6 −0 packages/svelte/CHANGELOG.md
  2. +1 −1 packages/svelte/package.json
  3. +12 −2 packages/svelte/src/internal/client/proxy.js
  4. +1 −1 packages/svelte/src/version.js
6 changes: 6 additions & 0 deletions packages/svelte/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# svelte

## 5.25.1

### Patch Changes

- fix: prevent dev server from throwing errors when attempting to retrieve the proxied value of an iframe's contentWindow ([#15577](https://github.com/sveltejs/svelte/pull/15577))

## 5.25.0

### Minor Changes
2 changes: 1 addition & 1 deletion packages/svelte/package.json
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
"name": "svelte",
"description": "Cybernetically enhanced web apps",
"license": "MIT",
"version": "5.25.0",
"version": "5.25.1",
"type": "module",
"types": "./types/index.d.ts",
"engines": {
14 changes: 12 additions & 2 deletions packages/svelte/src/internal/client/proxy.js
Original file line number Diff line number Diff line change
@@ -366,8 +366,18 @@ function update_version(signal, d = 1) {
* @param {any} value
*/
export function get_proxied_value(value) {
if (value !== null && typeof value === 'object' && STATE_SYMBOL in value) {
return value[STATE_SYMBOL];
try {
if (value !== null && typeof value === 'object' && STATE_SYMBOL in value) {
return value[STATE_SYMBOL];
}
} catch {
// the above if check can throw an error if the value in question
// is the contentWindow of an iframe on another domain, in which
// case we want to just return the value (because it's definitely
// not a proxied value) so we don't break any JavaScript interacting
// with that iframe (such as various payment companies client side
// JavaScript libraries interacting with their iframes on the same
// domain)
}

return value;
2 changes: 1 addition & 1 deletion packages/svelte/src/version.js
Original file line number Diff line number Diff line change
@@ -4,5 +4,5 @@
* The current version, as set in package.json.
* @type {string}
*/
export const VERSION = '5.25.0';
export const VERSION = '5.25.1';
export const PUBLIC_VERSION = '5';