Skip to content

Commit 162a13c

Browse files
exarusLinusBorg
authored andcommitted
Typo, whitespace and Style Guide fixes (#1231)
* Comment typo fixed in /build TypeScript comment typo in file /build/build.js * Whitespace refactoring in Unit tests * App component name PascalCase ESLint 'plugin:vue/recommended' detects this code style error. It violates the Style Guide rule: https://vuejs.org/v2/style-guide/#Component-name-casing-in-templates-strongly-recommended * Style Guide refactoring: HelloWorld.vue ESLint 'plugin:vue/recommended' detects the code style error in src/components/HelloWorld.js. It violates the Style Guide Strongly Recommended Rule: https://vuejs.org/v2/style-guide/#Multi-attribute-elements-strongly-recommended
1 parent 4cbca09 commit 162a13c

File tree

4 files changed

+75
-12
lines changed

4 files changed

+75
-12
lines changed

template/build/build.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ rm(path.join(config.build.assetsRoot, config.build.assetsSubDirectory), err => {
2222
process.stdout.write(stats.toString({
2323
colors: true,
2424
modules: false,
25-
children: false, // if you are using ts-loader, setting this to true will make tyescript errors show up during build
25+
children: false, // if you are using ts-loader, setting this to true will make typescript errors show up during build
2626
chunks: false,
2727
chunkModules: false
2828
}) + '\n\n')

template/src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import HelloWorld from './components/HelloWorld'
1515
1616
{{/unless}}
1717
export default {
18-
name: 'app'{{#router}}{{else}},
18+
name: 'App'{{#router}}{{else}},
1919
components: {
2020
HelloWorld
2121
}{{/router}}

template/src/components/HelloWorld.vue

Lines changed: 72 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,82 @@
33
<h1>\{{ msg }}</h1>
44
<h2>Essential Links</h2>
55
<ul>
6-
<li><a href="https://vuejs.org" target="_blank">Core Docs</a></li>
7-
<li><a href="https://forum.vuejs.org" target="_blank">Forum</a></li>
8-
<li><a href="https://chat.vuejs.org" target="_blank">Community Chat</a></li>
9-
<li><a href="https://twitter.com/vuejs" target="_blank">Twitter</a></li>
6+
<li>
7+
<a
8+
href="https://vuejs.org"
9+
target="_blank"
10+
>
11+
Core Docs
12+
</a>
13+
</li>
14+
<li>
15+
<a
16+
href="https://forum.vuejs.org"
17+
target="_blank"
18+
>
19+
Forum
20+
</a>
21+
</li>
22+
<li>
23+
<a
24+
href="https://chat.vuejs.org"
25+
target="_blank"
26+
>
27+
Community Chat
28+
</a>
29+
</li>
30+
<li>
31+
<a
32+
href="https://twitter.com/vuejs"
33+
target="_blank"
34+
>
35+
Twitter
36+
</a>
37+
</li>
1038
<br>
11-
<li><a href="http://vuejs-templates.github.io/webpack/" target="_blank">Docs for This Template</a></li>
39+
<li>
40+
<a
41+
href="http://vuejs-templates.github.io/webpack/"
42+
target="_blank"
43+
>
44+
Docs for This Template
45+
</a>
46+
</li>
1247
</ul>
1348
<h2>Ecosystem</h2>
1449
<ul>
15-
<li><a href="http://router.vuejs.org/" target="_blank">vue-router</a></li>
16-
<li><a href="http://vuex.vuejs.org/" target="_blank">vuex</a></li>
17-
<li><a href="http://vue-loader.vuejs.org/" target="_blank">vue-loader</a></li>
18-
<li><a href="https://github.com/vuejs/awesome-vue" target="_blank">awesome-vue</a></li>
50+
<li>
51+
<a
52+
href="http://router.vuejs.org/"
53+
target="_blank"
54+
>
55+
vue-router
56+
</a>
57+
</li>
58+
<li>
59+
<a
60+
href="http://vuex.vuejs.org/"
61+
target="_blank"
62+
>
63+
vuex
64+
</a>
65+
</li>
66+
<li>
67+
<a
68+
href="http://vue-loader.vuejs.org/"
69+
target="_blank"
70+
>
71+
vue-loader
72+
</a>
73+
</li>
74+
<li>
75+
<a
76+
href="https://github.com/vuejs/awesome-vue"
77+
target="_blank"
78+
>
79+
awesome-vue
80+
</a>
81+
</li>
1982
</ul>
2083
</div>
2184
</template>

template/test/unit/specs/HelloWorld.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ describe('HelloWorld.vue', () => {
66
const Constructor = Vue.extend(HelloWorld)
77
const vm = new Constructor().$mount()
88
expect(vm.$el.querySelector('.hello h1').textContent)
9-
{{#if_eq runner "karma"}}.to.equal('Welcome to Your Vue.js App'){{/if_eq}}{{#if_eq runner "jest"}}.toEqual('Welcome to Your Vue.js App'){{/if_eq}}
9+
{{#if_eq runner "karma"}}.to.equal('Welcome to Your Vue.js App'){{/if_eq}}{{#if_eq runner "jest"}}.toEqual('Welcome to Your Vue.js App'){{/if_eq}}
1010
})
1111
})

0 commit comments

Comments
 (0)