Skip to content

Commit

Permalink
docs: new version and debugMode
Browse files Browse the repository at this point in the history
  • Loading branch information
mcatta committed Jul 5, 2023
1 parent 758f015 commit feb8a0b
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@ repositories {
mavenCentral()
}
dependencies {
implementation 'dev.mcatta:polpetta:0.0.4'
implementation 'dev.mcatta:polpetta:0.0.5'
}
```
The full reference documentation [is available here](https://mcatta.github.io/polpetta/docs).

## How it works
You application's State must extend `State` and your action the `Action` class. Every `Action` can prompt a `Reducer` which basically manipulate your State.
Expand Down Expand Up @@ -62,6 +63,15 @@ class CounterStore(scope: CoroutineScope) : StateStore<CounterAction, CounterSta
}
)
```
You can add the `debugMode = true` to enable the logging.
```kotlin
StateStore<CounterAction, CounterState, MySideEffect>(
coroutineScope = scope,
debugMode = true,
initialState = CounterState.Count(0),
reducerFactory = {}
)
```

## Supported StateModifiers

Expand Down

0 comments on commit feb8a0b

Please sign in to comment.