Skip to content

Commit 92b0f57

Browse files
combine demo and docs in GH pages website
1 parent 1b076e2 commit 92b0f57

File tree

2 files changed

+13
-4
lines changed

2 files changed

+13
-4
lines changed

.github/workflows/docs.yml .github/workflows/website.yml

+12-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Deploy documentation
1+
name: Deploy website to GitHub Pages
22
on:
33
push:
44
branches:
@@ -12,13 +12,21 @@ jobs:
1212
- uses: actions/checkout@v4
1313
- name: Setup node.js
1414
uses: actions/setup-node@v4
15-
- name: Install
15+
- name: Install library
1616
run: |
1717
npm install
1818
- name: Build documentation
1919
run: |
2020
npm run docs
21-
- name: Deploy documentation
21+
- name: Build demo application
22+
run: |
23+
cd demo
24+
npm install
25+
npm install .. --install-links
26+
npm run build
27+
cd ..
28+
cp -R docs demo/dist
29+
- name: Deploy website
2230
uses: JamesIves/github-pages-deploy-action@v4
2331
with:
24-
folder: docs
32+
folder: demo/dist

demo/src/App.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ function App() {
7979
return (
8080
<Container id="main-container">
8181
<h1>Elasticsearch Request Converter Demo</h1>
82+
<p><a href="./docs/index.html">Library documentation</a></p>
8283
<Row>
8384
<Col className="col-6">
8485
<Stack direction="horizontal" className="heading">

0 commit comments

Comments
 (0)