mbellydo / vue3-vuex-exercise

Repository from Github https://github.commbellydo/vue3-vuex-exerciseRepository from Github https://github.commbellydo/vue3-vuex-exercise

vue3-vuex-exercise

Exercise N°9

  1. Install all dependencies and the vuex dependency. Execute the program as it is and try to understand the full funcionality; and what are the purpouse of "inject" and "provide" properties. Also, how the custom events are used.

  2. Fill the src/store/index.js with a global store to handle user login state. Remove the auth.isUserLogged property from App.vue, use a store getter to check if you user is connected.

  3. Remove inject from LoginForm.vue. Write login commit to set auth.isUserLogged to true.

  4. Remove injectfrom TheNavigation.vue. Create a getter in store/index.js with the name isUserLogged to perform the same action.

  5. Remove injectfrom TodoList.vue. Use a getter for todo and isUserLogged. Write a commit to perform the remove todo functionality.

  6. Remove inject from AddTodo.vue. Use the getter isUserLogged. Write a commit to perform the add todo functionality.

Project setup

npm install

Compiles and hot-reloads for development

npm run serve

Compiles and minifies for production

npm run build

Lints and fixes files

npm run lint

Customize configuration

See Configuration Reference.

About


Languages

Language:Vue 74.4%Language:JavaScript 17.9%Language:HTML 7.8%