File tree Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Expand file tree Collapse file tree 3 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ name: Deploy static content to Pages
4
4
on :
5
5
# Runs on pushes targeting the default branch
6
6
push :
7
- branches : [" main" ]
7
+ branches : [' main' ]
8
8
9
9
# Allows you to run this workflow manually from the Actions tab
10
10
workflow_dispatch :
@@ -18,7 +18,7 @@ permissions:
18
18
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
19
19
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
20
20
concurrency :
21
- group : " pages"
21
+ group : ' pages'
22
22
cancel-in-progress : false
23
23
24
24
jobs :
@@ -31,13 +31,15 @@ jobs:
31
31
steps :
32
32
- name : Checkout
33
33
uses : actions/checkout@v4
34
+ - name : Build
35
+ run : npm run demo:build
34
36
- name : Setup Pages
35
37
uses : actions/configure-pages@v5
36
38
- name : Upload artifact
37
39
uses : actions/upload-pages-artifact@v3
38
40
with :
39
41
# Upload entire repository
40
- path : ' ./demo /'
42
+ path : ' ./dist /'
41
43
- name : Deploy to GitHub Pages
42
44
id : deployment
43
45
uses : actions/deploy-pages@v4
Original file line number Diff line number Diff line change @@ -3,3 +3,6 @@ node_modules
3
3
4
4
# npmrc
5
5
.npmrc
6
+
7
+ # build
8
+ dist
Original file line number Diff line number Diff line change 15
15
"types" : " ./src/index.d.ts" ,
16
16
"scripts" : {
17
17
"dev" : " vite demo" ,
18
- "format" : " prettier --write" ,
18
+ "demo:build" : " vite build --outDir ../dist --emptyOutDir ./demo" ,
19
+ "format" : " prettier --write --ignore-unknown" ,
19
20
"release" : " release-it" ,
20
21
"prepare" : " husky"
21
22
},
You can’t perform that action at this time.
0 commit comments