Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1136524

Browse files
committed
cleanup action logs
Signed-off-by: shmck <shawn.j.mckay@gmail.com>
1 parentefda471 commit1136524

File tree

3 files changed

+3
-8
lines changed

3 files changed

+3
-8
lines changed

‎web-app/src/services/state/actions/context.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export const updatePosition = assign({
4747
})
4848

4949
exportconstloadNext=send((context:T.MachineContext):T.Action=>{
50-
constlevel=selectors.currentLevel(context)
50+
constlevel:TT.Level=selectors.currentLevel(context)
5151
returngetNext(context.position,level,context.tutorial?.levels||[])
5252
})
5353

‎web-app/src/services/state/machine.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ export const createMachine = (options: any) => {
204204
},
205205
LevelComplete:{
206206
onEntry:['onLevelComplete'],
207-
onExit:['testClear','incrementLevel'],
207+
onExit:['testClear'],
208208
on:{
209209
NEXT_LEVEL:'LoadNext',
210210
KEY_PRESS_ENTER:'LoadNext',

‎web-app/src/services/state/useStateMachine.tsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,6 @@ const editorSend = (action: T.Action) =>
2525
constuseStateMachine=():Output=>{
2626
const[state,send]=useMachine<T.MachineContext,any>(createMachine({ editorSend}))
2727

28-
constsendWithLog=(action:T.Action):void=>{
29-
logger(action)
30-
send(action)
31-
}
32-
3328
// event bus listener
3429
React.useEffect(()=>{
3530
constlistener='message'
@@ -57,7 +52,7 @@ const useStateMachine = (): Output => {
5752
return{
5853
context:state.context,
5954
route,
60-
send:sendWithLog,
55+
send,
6156
}
6257
}
6358

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp