-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: restrict invoked subscribable to eventobject
BREAKING Signed-off-by: Wouter Termont <woutermont@gmail.com>
- Loading branch information
1 parent
14cdef6
commit 18789aa
Showing
2 changed files
with
14 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
'xstate': major | ||
--- | ||
|
||
This update restricts invoked `Subscribable`s to `EventObject`s, | ||
so that type inference can be done on which `Subscribable`s are | ||
allowed to be invoked. | ||
|
||
Existing `MachineConfig`s that invoke `Subscribable`s that are not | ||
`Subscribable<EventObject>`s should be updated accordingly: | ||
either their emissions are desired, and should thus be acted on | ||
as events, or they are not, in which case an action would | ||
probably be a better choice than a service. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters