0.0.41 • Published 5 months ago
@katch-language/ts v0.0.41
katch – static event-oriented application glue
import {Katch} from 'katch';
@Katch
class cat {
static event() {
cat.event.bited = Katch.event();
cat.event.murred = Katch.event();
}
static request() {
cat.request.food = Katch.request();
}
@Katch
make_mur() {
katch(human.event.touchedCat, {Human: this.Owner});
console.log('Cat: mur');
}
@Katch
make_bite() {
let [, {Human}] = katch(human.event.touchedCat, {Human: $ => $ !== this.Owner }, );
console.log('Cat bite', Human);
}
@Katch
murring(process) {
this.make_mur();
}
}
@Katch
class human {
@Katch
pet() {
katch(cat.event.murred);
console.log('Human: *pet cat');
}
@Katch
test_in_context() {
katch(apartment.cat.)
}
}
export {cat, human};
run it using shell command:
node -r ts-node/register/transpile-only --nolazy --inspect katch.ts --init-context=cat,human,scene
0.0.41
5 months ago
0.0.40
5 months ago
0.0.38
5 months ago
0.0.39
5 months ago
0.0.37
5 months ago
0.0.36
5 months ago
0.0.35
5 months ago
0.0.34
5 months ago
0.0.33
5 months ago
0.0.32
5 months ago
0.0.31
5 months ago
0.0.30
5 months ago
0.0.29
5 months ago
0.0.28
5 months ago
0.0.27
5 months ago
0.0.26
5 months ago
0.0.25
5 months ago
0.0.24
5 months ago
0.0.23
5 months ago
0.0.22
5 months ago
0.0.21
5 months ago
0.0.20
5 months ago
0.0.19
5 months ago
0.0.18
5 months ago
0.0.17
5 months ago
0.0.16
5 months ago
0.0.15
5 months ago
0.0.14
5 months ago
0.0.13
5 months ago
0.0.12
5 months ago
0.0.11
5 months ago
0.0.10
5 months ago
0.0.9
5 months ago
0.0.8
5 months ago
0.0.7
5 months ago
0.0.6
5 months ago
0.0.2
5 months ago
0.0.1
5 months ago