Module 5 - Vue behind the scenes Flashcards

1
Q

What are the creation lifecycle events Vue has?

A
The Vue lifecycle events are :
beforeCreate
created
beforeMount
Mounted
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are the event changes life cycle hooks Vue has?

A

the event changes life cycle hooks Vue has:
beforeUpdate
updated

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does unmount do?

A

unmounting a vue app first goes through the beforeUnmount lifecycle hook and then the unmounted lifecycle hook

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Where do you add the Vue lifecycle hooks ?

A

The lifecycle methods are added to the config object provided in the createApp method.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How does Vue know when to do stuff?

A

Vue takes all the fields that are mentioned in the Data config section and puts them in a global object together with the methods in methods section. It monitors , using proxies, all the data fields and reacts to changes to those fields (like recomputing computed fields or calling functions in watch.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

what is a Proxy?

A

The Proxy object enables you to create a proxy for another object, which can intercept and redefine fundamental operations for that object.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Can more than one app be used

A

Yes, you can define one app per one template

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is a template

A

A template is the part of the HTML that is controlled by
Vue. You mount the app on the html element you want to control. You can also define the template inside the app in a template section

How well did you know this?
1
Not at all
2
3
4
5
Perfectly