Skip to content

Commit bdb292e

Browse files
committed
(docs) include demo
1 parent bdd302f commit bdb292e

File tree

4 files changed

+25
-13
lines changed

4 files changed

+25
-13
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ npm-debug.log
77
docs/.vuepress/dist
88
docs/.vuepress/.cache
99
docs/.vuepress/.temp
10+
docs/.vuepress/public/demo

deploy.sh

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,16 @@
33
# abort on errors
44
set -e
55

6+
# build demo
7+
cd demo
8+
npm run build
9+
cd ..
10+
11+
# copy demo files to vuepress public dir
12+
mkdir -p docs/.vuepress/public/demo/dist
13+
cp demo/index.html docs/.vuepress/public/demo/index.html
14+
cp demo/dist/build.js docs/.vuepress/public/demo/dist/build.js
15+
616
# build
717
npm run docs:build
818

@@ -11,8 +21,8 @@ cd docs/.vuepress/dist
1121

1222
git init
1323
git add -A
14-
git commit -m 'Deplying docs'
24+
git commit -m 'Deploying docs'
1525

1626
git push -f [email protected]:febe95/vue-js-modal.git master:gh-pages
1727

18-
cd -
28+
cd -

docs/.vuepress/config.js

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,9 @@ export default defineUserConfig({
1919
{ text: 'Github', link: 'https://github.com/febe95/vue-js-modal' },
2020
{ text: 'Vue 2', link: 'https://euvl.github.io/vue-js-modal/' },
2121
{
22-
text: 'Examples',
23-
children: [
24-
{
25-
text: 'Demo',
26-
link: 'https://febe95.github.io/vue-js-modal/demo'
27-
},
28-
{
29-
text: 'SSR (Nuxt)',
30-
link: 'https://febe95.github.io/vue-js-modal/examples/nuxt/'
31-
}
32-
]
22+
text: 'Demo',
23+
link: 'https://febe95.github.io/vue-js-modal/demo/',
24+
// target: '_self'
3325
}
3426
]
3527
})

docs/.vuepress/sidebar.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,14 @@ export default [
1010
'/Slots',
1111
'/Other'
1212
]
13+
},
14+
{
15+
text: 'Examples',
16+
children: [
17+
{
18+
text: 'Demo',
19+
link: 'https://febe95.github.io/vue-js-modal/demo/'
20+
}
21+
]
1322
}
1423
]

0 commit comments

Comments
 (0)