felangel / felangel/flow_builder
.set in addition to .update
- Ngôn ngữ chính
- Dart
- Star
- 416
- Fork
- 68
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
**Is your feature request related to a problem? Please describe.**
Whenever I want to transition to a new flow state without caring about the current flow state, I don't want to write more code of the form:
```dart
context
.flow()
.update((currentStateIDontCareAbout) => NewState())
```
**Describe the solution you'd like**
I'd like to see a more consise version of the form:
```dart
context
.flow()
.set(NewState())
```
This isn't a _big_ deal -- just seems like a natural function to have.
PS.
I know I can use `.update((_) => NewState())` to make it more concise, but I'd just pass in the state directly.
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Đánh giá
Issue này chưa được đánh giá.