Skip to content

Commit dbab68b

Browse files
committed
Doc: Adding example Vue app
1 parent 8ef4b12 commit dbab68b

File tree

5 files changed

+45
-12
lines changed

5 files changed

+45
-12
lines changed

docs/.vuepress/config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ module.exports = {
3333
]
3434
},
3535
{
36-
title: 'How to',
36+
title: 'Examples',
3737
collapsable: false,
3838
children: [
3939
'/demos/',

docs/demos/README.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1-
# Use in Vue
1+
# Vue app
22

3-
### Coming soon
3+
<iframe
4+
src="https://codesandbox.io/embed/vue-announcer-vue-project-z049t?fontsize=14&hidenavigation=1&theme=dark&view=editor"
5+
style="width:100%; height:500px; border:0; border-radius: 4px; overflow:hidden;"
6+
title="vue-announcer-vue-project"
7+
allow="accelerometer; ambient-light-sensor; camera; encrypted-media; geolocation; gyroscope; hid; microphone; midi; payment; usb; vr"
8+
sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
9+
></iframe>
10+
11+
<a href="https://codesandbox.io/s/vue-announcer-vue-project-z049t" target="_blank" rel="noopener">Open Sandbox example</a>

docs/demos/nuxt.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
# Use in Nuxt.js
1+
# Nuxt.js
22

33
### Coming soon

docs/demos/vuepress.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
# Use in Vuepress
1+
# Vuepress
22

33
### Coming soon

example/src/App.vue

Lines changed: 32 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,48 @@
11
<template>
22
<div id="app">
33
<!-- data-va is used for internal testing, it is not required -->
4-
<vue-announcer data-va="announcer"/>
4+
<vue-announcer data-va="announcer" />
55
<header>
6-
<router-link to="/" title="Vue.js logo" aria-label="Go to home page">
7-
<img src="./assets/logo.png" alt="Vue.js logo">
6+
<router-link
7+
to="/"
8+
title="Vue.js logo"
9+
aria-label="Go to home page"
10+
>
11+
<img
12+
src="./assets/logo.png"
13+
alt="Vue.js logo"
14+
>
815
</router-link>
916
<h1>{{ msg }}</h1>
1017
<h2>Essential Links</h2>
1118
<nav>
1219
<ul>
1320
<li>
14-
<router-link to="/posts/1" title="Go to post one page" aria-label="Go to example post page">My post</router-link>
21+
<router-link
22+
to="/posts/1"
23+
title="Go to post one page"
24+
aria-label="Go to example post page"
25+
>
26+
My post
27+
</router-link>
1528
</li>
1629
<li>
17-
<router-link to="/about" title="Go to about page" aria-label="Go to about page">About</router-link>
30+
<router-link
31+
to="/about"
32+
title="Go to about page"
33+
aria-label="Go to about page"
34+
>
35+
About
36+
</router-link>
1837
</li>
1938
<li>
20-
<router-link to="/contact" title="Go to contact page" aria-label="Go to contact page">Contact</router-link>
39+
<router-link
40+
to="/contact"
41+
title="Go to contact page"
42+
aria-label="Go to contact page"
43+
>
44+
Contact
45+
</router-link>
2146
</li>
2247
</ul>
2348
</nav>
@@ -32,7 +57,7 @@
3257

3358
<script>
3459
export default {
35-
name: 'app',
60+
name: 'App',
3661
data () {
3762
return {
3863
msg: 'Welcome to Your Vue.js App'

0 commit comments

Comments
 (0)