vue mouseover

Solutions on MaxInterview for vue mouseover by the best coders in the world

showing results for - "vue mouseover"
Anthony
08 Sep 2017
1<template>
2  <div
3    @mouseover="hover = true"
4    @mouseleave="hover = false"
5  />
6</template>
Eden
30 Jul 2019
1<style>
2		.pink {
3            background-color: pink;
4        }
5        .branco {
6            background-color: white;
7        }
8</style>
9<body>
10
11	<div id="app">
12    	<div 
13            class="borda div-comum" 
14            @mouseover="mudarCor('pink')" 
15            @mouseleave="mudarCor('branco')">
16        </div>
17   	</div>
18    
19    <script>
20
21        options = {
22            el: '#app',
23            data: {
24                cor: ''
25            },
26            methods: {
27                mudarCor(c) {
28                    this.cor = c;
29                    console.log(c);
30                    console.log('Cor : ' , this.cor);
31                }
32            },
33        }
34        const vm = new Vue(options);
35        console.log(vm);
36
37    </script>
38    
39</body>
similar questions
queries leading to this page
vue mouseover