-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathexample_01.html
More file actions
49 lines (43 loc) · 1.5 KB
/
example_01.html
File metadata and controls
49 lines (43 loc) · 1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<!DOCTYPE html>
<html lang="en">
<head>
<title>Vue.js Example 01</title>
<link rel="stylesheet" type="text/css" href="bootstrap-3.3.7-dist/css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="styles/site.css">
<script src="lib/[email protected]"></script>
</head>
<body>
<div id="app">
<div class="jumbotron">
<div class="container text-center">
<h1>{{ greeting }}</h1>
</div>
</div>
</div>
<script>
/**
We start a new Vue app. All it takes is `var app = new Vue()`;
We give it an element ('el') so the App will know
where to render our greeting.
We would like to display 'Hello Vue World !'.
To do so we declare a variable in the data section.
We name the variable 'greeting' and assign to it our message.
In the HTML we mention where we want the Greeting to be displayed
with the help our curly braces {{ greeting }}.
*/
var app = new Vue({
el: '#app',
data: function () {
return {
greeting: 'Hello Vue World !'
};
}
});
</script>
</body>
</html>
<!--
Example 01:
Write your own Greeting:
Hello CodHer, My name is: [your name]
-->