Created
March 18, 2019 06:28
-
-
Save earth774/1c1c2585f5b47a02d9535617ae71ce48 to your computer and use it in GitHub Desktop.
2 way data binding input
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> | |
| <meta charset="UTF-8"> | |
| <title>Amiearth</title> | |
| <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> | |
| </head> | |
| <body> | |
| <div id="app"> | |
| <input v-model="message" placeholder="edit me"> | |
| <p>Message is: {{ message }}</p> | |
| </div> | |
| <script> | |
| var example2 = new Vue({ | |
| el: '#app', | |
| data: { | |
| message: 'Vue.js' | |
| } | |
| }) | |
| </script> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment