Skip to content

Commit 1b87e08

Browse files
committed
CI: Fix vite build paths and migrate to npm ci (#63)
CI: Fix vite build paths and migrate to npm ci(#61) This reverts commit d667c9e. Update 'npm i' to 'npm ci' (#60) CI: Fix build folder for deploy script (#61) * update npm i to npm ci * fix build folder Fix vite absolute paths for deployment (#62) * update npm i to npm ci * fix build folder * revert folder change * fix vite build issue for deployment * fix vite paths * Fix step title
1 parent 7f41af4 commit 1b87e08

File tree

2 files changed

+10
-8
lines changed

2 files changed

+10
-8
lines changed

.github/workflows/deploy.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,32 +12,33 @@ jobs:
1212
- name: Get sources
1313
uses: actions/checkout@v3
1414

15-
- name: Use Node.js
16-
uses: actions/setup-node@v3
15+
- name: Use Node.js 20
16+
uses: actions/setup-node@v4
1717
with:
18-
node-version: '20'
18+
node-version: '20.19.0'
1919

2020
- name: Restore npm cache
2121
uses: actions/cache@v3
2222
with:
2323
path: ./node_modules
2424
key: ${{ runner.os }}-node-modules
2525

26-
- name: Run npm install
27-
run: npm install --no-audit --no-fund
26+
- name: Install dependencies (npm ci)
27+
run: npm ci --no-audit --no-fund
2828

2929
- name: Install Internal Package
3030
uses: DevExpress/github-actions/install-internal-package@main
3131

3232
- name: Build
3333
run: |
34-
npm pkg set homepage='https://devexpress.github.io/devextreme-react-template'
34+
rm -rf dist
3535
npm run build
3636
3737
- name: Deploy
3838
uses: JamesIves/github-pages-deploy-action@ba1486788b0490a235422264426c45848eac35c6
3939
with:
4040
branch: gh-pages
41-
folder: build
41+
folder: dist
42+
clean: true
4243
target-folder: .
4344

vite.config.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import { defineConfig } from 'vite'
22
import react from '@vitejs/plugin-react'
33

4-
// https://vite.dev/config/
4+
55
export default defineConfig({
6+
base: '/devextreme-react-template/',
67
plugins: [react()],
78
})

0 commit comments

Comments
 (0)