For forcePage to function correctly as a controlled component, it is more appropriate to directly assign the forcePage prop instead of using state for managing it. Instead of setting forcePage in the initial state and then matching it in componentDidMount, utilizing the forcePage prop directly is recommended. If forcePage and the internal selected state are in sync, there should be no issues. However, if different values are assigned, the page will be activated using the selected state and then revert back to forcePage.
For forcePage to function correctly as a controlled component, it is more appropriate to directly assign the forcePage prop instead of using state for managing it. Instead of setting forcePage in the initial state and then matching it in componentDidMount, utilizing the forcePage prop directly is recommended. If forcePage and the internal selected state are in sync, there should be no issues. However, if different values are assigned, the page will be activated using the selected state and then revert back to forcePage.