Skip to content

Conversation

@rodrigobnogueira
Copy link

Addresses issue #541 by clarifying that conditional transitions are evaluated in declaration order (when state.to() is called), not in the order they appear when combined with the | operator.

Changes:

  • Update description to explicitly mention "declaration order"
  • Add Important note box with clear examples showing:
    • How declaration order differs from composition order
    • Common pitfall where variable names don't match check order
    • Correct way to control evaluation order

This documentation fix helps prevent user confusion about which transition will be checked first when using multiple conditional transitions for the same event.

Closes #541

Addresses issue fgmacedo#541 by clarifying that conditional transitions are
evaluated in declaration order (when state.to() is called), not in
the order they appear when combined with the | operator.

Changes:
- Update description to explicitly mention "declaration order"
- Add Important note box with clear examples showing:
  - How declaration order differs from composition order
  - Common pitfall where variable names don't match check order
  - Correct way to control evaluation order

This documentation fix helps prevent user confusion about which
transition will be checked first when using multiple conditional
transitions for the same event.

Closes fgmacedo#541
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Conditional transition evaluation order is confusing

1 participant