Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

svelte

Package Overview
Dependencies
Maintainers
3
Versions
820
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

svelte - npm Package Compare versions

Comparing version 5.11.0 to 5.11.1

2

package.json

@@ -5,3 +5,3 @@ {

"license": "MIT",
"version": "5.11.0",
"version": "5.11.1",
"type": "module",

@@ -8,0 +8,0 @@ "types": "./types/index.d.ts",

@@ -53,7 +53,2 @@ /** @import { Location } from 'locate-character' */

const location =
dev && !is_ignored(node, 'reactive_declaration_non_reactive_property')
? locator(/** @type {number} */ (node.start))
: undefined;
// these statements will be topologically ordered later

@@ -66,5 +61,3 @@ context.state.legacy_reactive_statements.set(

sequence.length > 0 ? b.thunk(b.sequence(sequence)) : b.thunk(b.block([])),
b.thunk(b.block(body)),
location && b.literal(location.line),
location && b.literal(location.column)
b.thunk(b.block(body))
)

@@ -71,0 +64,0 @@ )

@@ -145,3 +145,3 @@ /** @import { Visitors } from 'zimmerframe' */

// see them in devtools
if (!dev && is_empty(node)) {
if (!dev && is_empty(node, is_in_global_block(path))) {
if (state.minify) {

@@ -402,4 +402,7 @@ state.code.remove(node.start, node.end);

/** @param {Css.Rule} rule */
function is_empty(rule) {
/**
* @param {Css.Rule} rule
* @param {boolean} is_in_global_block
*/
function is_empty(rule, is_in_global_block) {
if (rule.metadata.is_global_block) {

@@ -415,3 +418,5 @@ return rule.block.children.length === 0;

if (child.type === 'Rule') {
if (is_used(child) && !is_empty(child)) return false;
if ((is_used(child) || is_in_global_block) && !is_empty(child, is_in_global_block)) {
return false;
}
}

@@ -418,0 +423,0 @@

@@ -47,4 +47,3 @@ export const EACH_ITEM_REACTIVE = 1;

'ownership_invalid_binding',
'ownership_invalid_mutation',
'reactive_declaration_non_reactive_property'
'ownership_invalid_mutation'
]);

@@ -51,0 +50,0 @@

@@ -268,6 +268,4 @@ /** @import { ComponentContext, ComponentContextLegacy, Derived, Effect, Reaction, TemplateNode, TransitionManager } from '#client' */

* @param {() => void | (() => void)} fn
* @param {number} [line]
* @param {number} [column]
*/
export function legacy_pre_effect(deps, fn, line, column) {
export function legacy_pre_effect(deps, fn) {
var context = /** @type {ComponentContextLegacy} */ (component_context);

@@ -279,7 +277,2 @@

if (DEV && line !== undefined) {
var location = get_location(line, column);
var explicit_deps = capture_signals(deps);
}
token.effect = render_effect(() => {

@@ -294,14 +287,3 @@ deps();

set(context.l.r2, true);
if (DEV && location) {
var implicit_deps = capture_signals(() => untrack(fn));
for (var signal of implicit_deps) {
if (!explicit_deps.has(signal)) {
w.reactive_declaration_non_reactive_property(/** @type {string} */ (location));
}
}
} else {
untrack(fn);
}
untrack(fn);
});

@@ -308,0 +290,0 @@ }

@@ -159,14 +159,2 @@ /* This file is generated by scripts/process-messages/index.js. Do not edit! */

/**
* A `$:` statement (%location%) read reactive state that was not visible to the compiler. Updates to this state will not cause the statement to re-run. The behaviour of this code will change if you migrate it to runes mode
* @param {string} location
*/
export function reactive_declaration_non_reactive_property(location) {
if (DEV) {
console.warn(`%c[svelte] reactive_declaration_non_reactive_property\n%cA \`$:\` statement (${location}) read reactive state that was not visible to the compiler. Updates to this state will not cause the statement to re-run. The behaviour of this code will change if you migrate it to runes mode\nhttps://svelte.dev/e/reactive_declaration_non_reactive_property`, bold, normal);
} else {
console.warn(`https://svelte.dev/e/reactive_declaration_non_reactive_property`);
}
}
/**
* Reactive `$state(...)` proxies and the values they proxy have different identities. Because of this, comparisons with `%operator%` will produce unexpected results

@@ -173,0 +161,0 @@ * @param {string} operator

@@ -9,3 +9,3 @@ // generated during release, do not modify

*/
export const VERSION = '5.11.0';
export const VERSION = '5.11.1';
export const PUBLIC_VERSION = '5';

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc