xstate-viz
                                
                                
                                
                                    xstate-viz copied to clipboard
                            
                            
                            
                        "after" animation kicks only once
Description
Assume following machine:
import { createMachine } from 'xstate';
const machine = createMachine(
  {
    id: 'doorman',
    initial: 'idle',
    states: {
      idle: {
        on: {
          ACTIVE_MEETING: 'working',
        },
      },
      working: {
        type: 'parallel',
        states: {
          ticking: {
            entry: [
              () => {
                console.log("entered a");
              }
            ],
            after: {
              1000: { target: 'ticking' }
            }
          },
        }
      },
    },
  },
);
export default machine;
Expected Result
The animation spinner for "after" should keep spinning over and over after the machine enters the "working" state.
Actual Result
Animation kicks only once.
Reproduction
See above
Additional context

I can confirm that this is a bug. It feels like React's key prop could be used here to fix this cheaply but OTOH there is no "clear" key that could be used here to fix it this way.