, , , . , . , , .
, , .
:
private state: State;
@computedFrom('state.activeSession')
, Aurelia , , Aurelia , . , , ( ), (.. , ), .
, , , , - , , -, - , . , :
private state: State;
TypeScript, state . , , JavaScript - state TypeScript.
, :
class A {
x: number;
}
JavaScript :
function A() {
}
, this.x! , :
class B {
x: number = undefined; // or null, or whatever you like
}
JavaScript :
function B() {
this.x = undefined;
}
, . - Aurelia , , ( JavaScript) . , :
var a = new A();
var b = new B();
console.log(a.x);
console.log(b.x);
a.x b.x undefined. : a.x is undefined, a, b.x - undefined, undefined - , undefined. Aurelia , .
, , , , (, undefined, null) , . .