Sometimes we may need to compute derived state based on store state, for example filtering through a list of items and counting them: computed: { doneTodosCount () { return this.$store.state.todos.filter(todo => todo.done).length } } If more than one component needs to make use of this, we have to either duplicate the function, or extract it into a shared helper and import it in multiple places ..