Question · Angular course · Module 10: State Management

The props function in an action

What is props<{ samurai: Samurai }>() used for when creating an action with createAction?

Answer options

  • It defines the type of the payload passed with the action
  • It creates a selector for that action
  • It registers an effect for the action
  • It sets the initial state of the reducer

You can check the correct answer by solving this task in the CodeWorlds game.