Skip to content

Commit 9eea504

Browse files
christianalfonigitbook-bot
authored andcommitted
GitBook: [v28] 44 pages modified
1 parent 2754e37 commit 9eea504

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

README.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,11 +94,10 @@ export const search = pipe(
9494
{% tab title="Statemachines" %}
9595
```typescript
9696
export const state = statemachine({
97-
SIGN_IN: (state) => {
98-
if (state.current === 'UNAUTHENTICATED') {
99-
return { current: 'AUTHENTICATING' }
100-
}
101-
}
97+
UNAUTHENTICATED: {
98+
SIGN_IN: () => ({ current: 'AUTHENTICATING' })
99+
},
100+
AUTHENTICATING: {}
102101
})
103102
```
104103
{% endtab %}

introduction.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ You have to **OPEN SANDBOX** to get the full Typescript experience.
241241

242242
{% embed url="https://codesandbox.io/s/overmind-todomvc-typescript-39h7y?fontsize=14&hidenavigation=1&theme=dark&view=editor&runonclick=1" %}
243243

244-
As you can see we only have to add an **Action** type to our functions and optionally give it an input type. This is enough for the action to give you all information about the application. Try changing some code and even add some code to see how Typescript helps you to explore the application and ensure that you implement new functionality correctly.
244+
As you can see we only have to add the **Context** type to our actions and optionally give it an input type. This is enough for the action to give you all information about the application. Try changing some code and even add some code to see how Typescript helps you to explore the application and ensure that you implement new functionality correctly.
245245

246246
If you go to the **state.ts** file and change the type:
247247

0 commit comments

Comments
 (0)