The error "TypeError: Cannot read property 'type' of undefined" is thrown
Some error should be thrown, but one that the developer can recognize and handle appropriately.
Your example of persisting state saves it in localStorage. Say my user saves the state on Monday, and by Tuesday, a column is removed, renamed, has a different type... I need to handle that user's deprecated saved state.