13
13
![ badge] [ badge-jvm ]
14
14
![ badge] [ badge-js ]
15
15
![ badge] [ badge-js-ir ]
16
+ ![ badge] [ badge-wasm ]
16
17
![ badge] [ badge-nodejs ]
17
18
![ badge] [ badge-linux ]
18
19
![ badge] [ badge-windows ]
134
135
135
136
- ` jvm ` / ` android ` .
136
137
- ` js ` (` IR ` ).
138
+ - ` wasmJs ` .
137
139
- ` Darwin ` targets:
138
140
- ` iosArm64 ` , ` iosX64 ` , ` iosSimulatorArm64 ` .
139
141
- ` watchosArm32 ` , ` watchosArm64 ` , ` watchosX64 ` , ` watchosSimulatorArm64 ` , ` watchosDeviceArm64 ` .
@@ -149,31 +151,31 @@ bus
149
151
an Android app using Compose UI to show how to use the library.
150
152
It has two nested navigation graphs: ` Register ` and ` Home ` .
151
153
152
- - In ` Register ` , we have 3 steps (3 screens) to allow user to input their information, step
154
+ - In ` Register ` , we have 3 steps (3 screens) to allow the user to input their information, step
153
155
by
154
156
step.
155
157
- A ` RegisterSharedViewModel ` (bound to ` Register ` navigation graph scope) is used
156
158
to hold the whole state of the registration process.
157
- It observes events from the ` ChannelEventBus ` and update the state accordingly.
159
+ It observes events from the ` ChannelEventBus ` and updates the state accordingly.
158
160
159
- - Each step screen has a ` ViewModel ` to hold the state of the screen, and will send events to
161
+ - Each step screen has a ` ViewModel ` to hold the state of the screen and will send events to
160
162
the ` ChannelEventBus ` ,
161
163
then the ` RegisterSharedViewModel ` will receive those events and update the state.
162
164
163
- - In ` Home ` nav graph, we have 2 screens: ` Home ` and ` Detail ` .
164
- - ` Home ` screen has a ` HomeViewModel ` to hold the results received from the ` Detail ` screen.
165
+ - In the ` Home ` nav graph, we have 2 screens: ` Home ` and ` Detail ` .
166
+ - The ` Home ` screen has a ` HomeViewModel ` to hold the results received from the ` Detail ` screen.
165
167
Those result events are sent from the ` Detail ` screen to the ` ChannelEventBus ` ,
166
168
and the ` HomeViewModel ` will receive those events and update the state.
167
169
168
- - ` Detail ` screen will send events to the ` ChannelEventBus ` when user clicks on the button.
170
+ - The ` Detail ` screen will send events to the ` ChannelEventBus ` when the user clicks on the button.
169
171
The ` HomeViewModel ` will receive those events and update the state.
170
172
171
173
https://github.com/hoc081098/kotlin-channel-event-bus/assets/36917223/80015232-d5b5-4fb2-a779-4e6113ddb8f8
172
174
173
175
## Roadmap
174
176
175
- - [ ] Support more targets: ` wasm ` (depends on supported targets by ` kotlinx.coroutines ` ).
176
- - [ ] More samples.
177
+ - [x ] Support more targets: ` wasm ` (depends on supported targets by ` kotlinx.coroutines ` ) (since [ 0.1.0 ] ( https://github.com/Kotlin-Multiplatform-Foundation/kotlin-channel-event-bus/releases/tag/0.1.0 ) ).
178
+ - [x ] More samples.
177
179
- [ ] More docs.
178
180
- [ ] More tests.
179
181
0 commit comments