Created
July 22, 2020 05:58
-
-
Save kertnik05/5d0489780f4623ed814f2d2362859e05 to your computer and use it in GitHub Desktop.
Vue Coding Challenge 1 Answer
This file contains 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
// Add a description to the data object | |
// with the value "A pair of warm, fuzzy | |
// socks". Then display the description using | |
// an expression in an p element, underneath | |
// the h1. | |
const app = new Vue({ | |
el: '#app', | |
data: { | |
product: 'Socks', | |
description: 'A pair of warm, fuzzy socks' // my answer to the coding challenge | |
} | |
}); |
This file contains 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 lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Vue Tuts</title> | |
<style> | |
</style> | |
</head> | |
<body> | |
<div id="app"> | |
<h1>{{ product }}</h1> | |
<p>{{ description }}</p> <!-- my answer to the coding challenge --> | |
</div> | |
<!-- development version, includes helpful console warnings --> | |
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> | |
<script src="./app.js"></script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment