Manually triggering actions
The ability to manually trigger actions during development of a Redux application can be helpful. For instance, you might have components ready, but you're unsure of how the user interaction will work or you just need to troubleshoot something that should be working but isn't. You can use Redux DevTools to manually trigger actions by clicking on the button with the keyboard icon, near the bottom of the pane:
This will display a text input where you can enter the action payload. For example, I've navigated to the book detail page for React Native By Example
:
Instead of clicking on the Delete
button, I only want to see what happens regarding the state of the application, without triggering DOM events or API calls. To do this, I can click on the keyboard button in Redux DevTools, which allows me to manually enter an action and dispatch it. For example, here is how I would dispatch the DELETING_BOOK
action:
This results in the action being dispatched and consequently...