When you increase the rating, it increases the copy (not the rating in games). So when I open another browser, I don't see the rating changes that the first browser made.
Marina Mosti is a full-stack web developer with over 14 years of experience in the field. She enjoys mentoring other women on JavaScript and her favorite framework, Vue.
Hey Eric! Well, the status of your component is not going to persist through browsers unless you're storing it somehow on a server and then authenticating a user, this is way beyond the scope of these tutorials.
In order to change the parent's data you need to communicate to the parent of the component that the child's data has changed. You can accomplish this with either events or vuex (or some sort of state management).
I will eventually get to this in the tutorials, but if you want to try to skip ahead take a look at the docs and read about $emit and how to fire an event from your child component. You will also need to use a watched property as well, so this is kind of advanced in regard to what we have covered
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Thanks for this lesson.
When you increase the rating, it increases the copy (not the rating in games). So when I open another browser, I don't see the rating changes that the first browser made.
How do I change the rating in games?
Hey Eric! Well, the status of your component is not going to persist through browsers unless you're storing it somehow on a server and then authenticating a user, this is way beyond the scope of these tutorials.
In order to change the parent's data you need to communicate to the parent of the component that the child's data has changed. You can accomplish this with either
events
orvuex
(or some sort of state management).I will eventually get to this in the tutorials, but if you want to try to skip ahead take a look at the docs and read about
$emit
and how to fire an event from your child component. You will also need to use awatch
ed property as well, so this is kind of advanced in regard to what we have covered