Q:

xstate state based on condition

 on:{
 EVENT_NAME:[
    // it goes to the first target that passes the cond(short for condition)
 	{ target: 'opened', cond: 'isAdmin' },
 	{ target: '.error', cond: 'shouldAlert' }] 
 }
0

New to Communities?

Join the community