質問するログイン新規登録

質問編集履歴

1

申し訳ありません。App.vueのソースを添付致します。

2018/09/07 03:22

投稿

pokemn
pokemn

スコア16

title CHANGED
File without changes
body CHANGED
@@ -25,7 +25,68 @@
25
25
  @ ./src/main.js
26
26
  @ multi (webpack)-dev-server/client?http://localhost:8080 webpack/hot/dev-server ./src/main.js
27
27
  ```
28
+ ### App.vue
29
+ ```
30
+ 1 <template>
31
+ 2 <div id="app">
32
+ 3 <h1>ToDoManagement</h1>
33
+ 4 <form>
34
+ 5 <input type="text" v-model="text-input">
35
+ 6 <input type="button" v-on:click="insert-button" name="登録">
36
+ 7 <p><span>{{textInput.length}}</span>文字</p>
37
+ 8
38
+ 9 </form>
39
+ 10 </div>
40
+ 11 </template>
41
+ 12
42
+
43
+ 13 <script>
44
+ 14 export default {
45
+ 15 name: 'app',
46
+ 16 data () {
47
+ 17 return {
48
+ 18 textInput: ''
49
+ 19 }
50
+ 20 },
51
+ 21 methods: {
52
+ 22 insertButton () {
53
+ 23 if (this.textInput === '') return
54
+ 24 }
55
+ 25 }
56
+ 26 }
57
+ 27 </script>
58
+ 28
59
+
60
+ 29 <style lang="scss">
61
+ 30 #app {
62
+ 31 font-family: 'Avenir', Helvetica, Arial, sans-serif;
63
+ 32 -webkit-font-smoothing: antialiased;
64
+ 33 -moz-osx-font-smoothing: grayscale;
65
+ 34 text-align: center;
66
+ 35 color: #2c3e50;
67
+ 36 margin-top: 60px;
68
+ 37 }
69
+ 38
70
+ 39 h1, h2 {
71
+ 40 font-weight: normal;
72
+ 41 }
73
+ 42
74
+ 43 ul {
75
+ 44 list-style-type: none;
76
+ 45 padding: 0;
77
+ 46 }
78
+ 47
79
+ 48 li {
80
+ 49 display: inline-block;
81
+ 50 margin: 0 10px;
82
+ 51 }
83
+ 52
84
+ 53 a {
85
+ 54 color: #42b983;
86
+ 55 }
87
+ 56 </style>
28
88
 
89
+ ```
29
90
 
30
91
  ### 試したこと
31
92