[Vuejs]-MapState with TypeScript is enforcing me to use watch on my Vue component state properties

0๐Ÿ‘

โœ…

Iโ€™ve found the problem, I did not nest the maps in computed.

@Component({
  components: {
    SomeComponent,
    ...
  },
  computed { // <--- This line solved it
    ...mapGetters(['currentSubscription']),
    ...mapState({
      content: (state: RootState) => state.content,
    })
  }
})

This way it is all working fine

Leave a comment