Check out a free preview of the full Vuex for Intermediate Vue 2 Developers course

The "Vuex Store" Lesson is part of the full, Vuex for Intermediate Vue 2 Developers course featured in this preview video. Here's what you'd learn in this lesson:

Divya explains that this section focuses on how Vuex is used daily by developers, and adds that the best practice is to isolate Vuex within the same file.

Preview
Close

Transcript from the "Vuex Store" Lesson

[00:00:00]
>> All right, so for the next section we're gonna talk about something, that's actually how we're using Vuex in real life. So the examples in the code that I showed you in the past two parts were mostly Vuex in CodePen. Which is a single Vuex view instance, which can be useful if you wanna do something really quick, if you wanna check whether, or not things work.

[00:00:22]
But oftentimes when you use Vuex, you're actually using it in the context of a single file component, which is how Vue is organized. So we want to be able to isolate Vuex, because in the CodePen examples, we had Vuex sitting in the same place that we have our Vue code, and that is generally not common practice.

Learn Straight from the Experts Who Shape the Modern Web

  • In-depth Courses
  • Industry Leading Experts
  • Learning Paths
  • Live Interactive Workshops
Get Unlimited Access Now