How to fix Subsequent property declarations must have the same type in TypeScript | DevErrors