I got this error while using redux-persist, I moved the types from other files (ie external modules) to above of the declaration of that variable throwing ts-error
It was complaining about two types(InitialStateOfControlSlice
, InitialStateOfProfileSlice
), so I just made sure they are in the same file.