alloc / alloc/wana

Shorthand syntax for "Auto" reactions

Offen
#11 4 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
enhancement
Vorherrschende Sprache
TypeScript
Sterne
176
Forks
9
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

"Reactions" are unobserved side effects in response to an observed computation.

The current way to do this:

```ts
auto(() => {
// Observed computation here
noto(() => {
// Unobserved side effects here
})
})
```

The proposed way to do this:

```ts
auto(
() => {
// Observed computation here
},
result => {
// Unobserved side effects here
}
)
```

The bonus (of course) being that you don't need to import `noto`.

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.