Skip to content

Commit b635224

Browse files
committed
Tweak readme
1 parent 1604ba2 commit b635224

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

readme.md

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,23 @@
33
<p>Composable State Machines using Generator Functions</p>
44
<div>
55
<a href="https://bundlephobia.com/result?p=yieldmachine">
6-
<img src="https://badgen.net/bundlephobia/minzip/yieldmachine@0.4.1" alt="minified and gzipped size">
7-
<img src="https://badgen.net/bundlephobia/min/yieldmachine@0.4.1" alt="minified size">
8-
<img src="https://badgen.net/bundlephobia/dependency-count/yieldmachine@0.4.1" alt="zero dependencies">
6+
<img src="https://badgen.net/bundlephobia/minzip/yieldmachine@0.4.9" alt="minified and gzipped size">
7+
<img src="https://badgen.net/bundlephobia/min/yieldmachine@0.4.9" alt="minified size">
8+
<img src="https://badgen.net/bundlephobia/dependency-count/yieldmachine@0.4.9" alt="zero dependencies">
99
</a>
1010
</div>
1111
</div>
1212

13-
## Overview
13+
## Goals
1414

15-
- Define state machine components using generators functions.
1615
- States can be reused.
1716
- Nest machines inside one another.
18-
- Use native JavaScript features such as Promise, AbortSignal, and EventTarget.
19-
- Conform various stateful things such as offline status, promises, fetch, IntersectionObserver, ResizeObserver, window.location. Manage these things in a consistent way with a consistent interface.
17+
- Interops with native JavaScript & browser features such as Promise, AbortSignal, and EventTarget.
18+
- Consistently use built-in browser features such as offline status, promises, fetch, IntersectionObserver, ResizeObserver, window.location. Manage these things in a consistent way with a consistent interface.
2019

21-
### Problems
20+
### Problems that state machines solve
2221

23-
+ Making sure my code is 100% robust and doesn't fall into inconsistent states is hard.
22+
- Making sure my code is 100% robust and doesn't fall into inconsistent states is hard.
2423
- It's easy to forget about error handling.
2524
- Built-in browser features (such as InteractionObserver) are powerful but a pain to manage correctly.
2625
- Managing various flavors of state is hard: the current URL, local storage, focused element, fetch response, caches, offline/online.

0 commit comments

Comments
 (0)