You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+93-7Lines changed: 93 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,13 +8,13 @@ description: frictionless state management
8
8
9
9
## APPLICATION INSIGHT
10
10
11
-
Develop the application state, effects and actions without leaving [VS Code](https://code.visualstudio.com/), or use the standalone development tool. Everything that happens in your app is tracked and you can seamlessly code and run logic to verify that everything works as expected without having to implement UI.
11
+
Develop the application state, effects and actions without leaving [VS Code](https://code.visualstudio.com/), or use the standalone development tool. Everything that happens in your app is tracked and you can seamlessly code and run logic to verify that everything works as expected without necessarily having to implement UI.
12
12
13
13

14
14
15
15
## A SINGLE STATE TREE
16
16
17
-
Building your application as a single state tree is the most straight forward mental model. You get a complete overview, but can still organize the state by namespacing it into domains. The devtools allows you to edit and mock out state.
17
+
Building your application with a single state tree is the most straight forward mental model. You get a complete overview, but can still organize the state by namespacing it into domains. The devtools allows you to edit and mock out state.
18
18
19
19
```typescript
20
20
{
@@ -32,15 +32,26 @@ Building your application as a single state tree is the most straight forward me
32
32
33
33
Separate 3rd party APIs and logic not specific to your application by using **effects**. This will keep your application logic pure and without low level APIs cluttering your code.
When pieces of logic become complex it is beneficial to write functional code. Overmind provides an API named **operators**which gives you functional power. Ignore it, use it where it makes sense or make your whole codebase functional. It is up to you!
70
+
Even though Overmind can create applications with only plain **state** and **actions**, you can use **opt-in**tools like **functional operators**, **statecharts** and state values defined as a **class,** to manage complexities of your application.
this.validationError='You need some numbers in your password'
143
+
}
144
+
this.password=password
145
+
}
146
+
isValid() {
147
+
return Boolean(this.username && this.password)
148
+
}
149
+
}
150
+
151
+
typeState= {
152
+
loginForm: LoginForm
153
+
}
154
+
155
+
exportconststate: State= {
156
+
loginForm: newLoginForm()
157
+
}
158
+
```
159
+
{% endtab %}
160
+
{% endtabs %}
75
161
76
162
## SNAPSHOT TESTING OF LOGIC
77
163
@@ -102,5 +188,5 @@ Overmind has you covered on typing. If you choose to use Typescript the whole AP
102
188
103
189

104
190
105
-
Overmind is running the main application of [codesandbox.io](https://codesandbox.io). With its state and effects complexity Codesandbox benefits greatly by Overmind using Typescript.
191
+
Overmind is running the main application of [codesandbox.io](https://codesandbox.io). Codesandbox, with its state and effects complexity, benefits greatly combining Overmind and Typescript.
0 commit comments