Created
December 24, 2017 07:10
-
-
Save jasperf/63f7cce8c50b8573b9179c0cff560722 to your computer and use it in GitHub Desktop.
VueJS v-model example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title></title> | |
</head> | |
<body> | |
<div id="root"> | |
<input type="text" name="input" v-model="message"> | |
<p>The value of the input is {{message}}</p> | |
</div> | |
<script src="https://unpkg.com/vue"></script> | |
<script> | |
let data = { | |
message: 'Hello World' | |
}; | |
new Vue({ | |
el: '#root', | |
data:data | |
}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment