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

@aurelia/runtime

Package Overview
Dependencies
Maintainers
0
Versions
1115
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aurelia/runtime - npm Package Compare versions

Comparing version 2.0.1-dev.202408081231 to 2.0.1-dev.202409300916

dist/types/ast.eval.d.ts

5

dist/types/index.d.ts

@@ -0,1 +1,4 @@

export { type IAstEvaluator, astAssign, astBind, astEvaluate, astUnbind, } from './ast.eval';
export { mixinNoopAstEvaluator, } from './ast.utilities';
export { Scope, BindingContext, type IBindingContext, type IOverrideContext, } from './scope';
export { type IObserverLocatorBasedConnectable, type IObserverRecord, connectable, } from './connectable';

@@ -8,3 +11,3 @@ export { type ArrayObserver, type ArrayIndexObserver, } from './array-observer';

export { IDirtyChecker, DirtyChecker, DirtyCheckProperty, DirtyCheckSettings, } from './dirty-checker';
export { type IEffect, IObservation, Observation, type EffectRunFunc, } from './effect-runner';
export { type IEffect, IObservation, Observation, type EffectRunFunc, } from './observation';
export { type IObservableDefinition, observable, } from './observable';

@@ -11,0 +14,0 @@ export { type IObjectObservationAdapter, IObserverLocator, INodeObserverLocator, IComputedObserverLocator, getCollectionObserver, ObserverLocator, getObserverLookup, type ObservableGetter, } from './observer-locator';

2

dist/types/observer-locator.d.ts
import { ArrayObserver } from './array-observer';
import { ComputedGetterFn } from './computed-observer';
import { MapObserver } from './map-observer';
import { PropertyAccessor } from './property-accessor';
import { SetObserver } from './set-observer';
import type { Collection, IAccessor, ICollectionObserver, IObserver, AccessorOrObserver, CollectionObserver } from './interfaces';
export declare const propertyAccessor: PropertyAccessor;
export interface IObjectObservationAdapter {

@@ -9,0 +7,0 @@ getObserver(object: unknown, key: PropertyKey, descriptor: PropertyDescriptor, requestor: IObserverLocator): IObserver | null;

{
"name": "@aurelia/runtime",
"version": "2.0.1-dev.202408081231",
"version": "2.0.1-dev.202409300916",
"main": "dist/cjs/index.cjs",

@@ -57,6 +57,6 @@ "module": "dist/esm/index.mjs",

"dependencies": {
"@aurelia/kernel": "2.0.1-dev.202408081231",
"@aurelia/expression-parser": "2.0.1-dev.202408081231",
"@aurelia/metadata": "2.0.1-dev.202408081231",
"@aurelia/platform": "2.0.1-dev.202408081231"
"@aurelia/kernel": "2.0.1-dev.202409300916",
"@aurelia/expression-parser": "2.0.1-dev.202409300916",
"@aurelia/metadata": "2.0.1-dev.202409300916",
"@aurelia/platform": "2.0.1-dev.202409300916"
},

@@ -63,0 +63,0 @@ "devDependencies": {

@@ -27,2 +27,6 @@ /* eslint-disable @typescript-eslint/no-unsafe-member-access */

ast_destruct_null = 112,
ast_increment_infinite_loop = 113,
ast_nullish_member_access = 114,
ast_nullish_keyed_access = 115,
ast_nullish_assignment = 116,

@@ -90,2 +94,6 @@ null_scope = 203,

[ErrorNames.ast_destruct_null]: `Ast eval error: cannot use non-object value for destructuring assignment.`,
[ErrorNames.ast_increment_infinite_loop]: `Ast eval error: infinite loop detected. Increment operators should only be used in event handlers.`,
[ErrorNames.ast_nullish_member_access]: `Ast eval error: cannot access property "{{0}}" of {{1}}.`,
[ErrorNames.ast_nullish_keyed_access]: `Ast eval error: cannot access key "{{0}}" of {{1}}.`,
[ErrorNames.ast_nullish_assignment]: `Ast eval error: cannot assign value to property "{{0}}" of null/undefined.`,

@@ -92,0 +100,0 @@ [ErrorNames.parse_invalid_start]: `Expression error: invalid start: "{{0}}"`,

export {
type IAstEvaluator,
astAssign,
astBind,
astEvaluate,
astUnbind,
} from './ast.eval';
export {
mixinNoopAstEvaluator,
} from './ast.utilities';
export {
Scope,
BindingContext,
type IBindingContext,
type IOverrideContext,
} from './scope';
export {
type IObserverLocatorBasedConnectable,

@@ -36,3 +55,3 @@ type IObserverRecord,

type EffectRunFunc,
} from './effect-runner';
} from './observation';
export {

@@ -51,3 +70,2 @@ type IObservableDefinition,

type ObservableGetter,
// type ObservableSetter,
} from './observer-locator';

@@ -54,0 +72,0 @@ export {

@@ -199,9 +199,9 @@ import { AccessorType, IAccessor, ISubscriberCollection, atObserver } from './interfaces';

this._value = value;
this.cb?.call(this._obj, this._value, this._oldValue);
// this._value might have been updated during the callback
// we only want to notify subscribers with the latest values
value = this._oldValue;
this._oldValue = this._value;
this.subs.notifyDirty();
this.subs.notify(this._value, value);
this.subs.notify(this._value, this._oldValue);
// if the value has been changed during the notify, don't call the callback
// it's the job of the last .setValue() to call the callback
if (areEqual(value, this._value)) {
this.cb?.call(this._obj, this._value, this._oldValue);
}
}

@@ -208,0 +208,0 @@ }

@@ -23,3 +23,3 @@ import { Primitive, isArrayIndex, ILogger, resolve, isFunction, isObject, isSet, isArray, isMap, createLookup } from '@aurelia/kernel';

export const propertyAccessor = new PropertyAccessor();
const propertyAccessor = new PropertyAccessor();

@@ -26,0 +26,0 @@ export interface IObjectObservationAdapter {

@@ -63,5 +63,11 @@ import { ICoercionConfiguration, IObserver, InterceptorFunc, atObserver } from './interfaces';

this._value = newValue;
this._callback?.(newValue, oV);
this.subs.notifyDirty();
this.subs.notify(newValue, oV);
// only call the callback if _value is the same with newValue
// which means if during subs.notify() the value of this observer is changed
// then it's the job of that setValue() to call the callback
if (areEqual(newValue, this._value)) {
this._callback?.(newValue, oV);
}
} else {

@@ -68,0 +74,0 @@ // If subscribe() has been called, the target property descriptor is replaced by these getter/setter methods,

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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