Skip to content

Commit 54346c0

Browse files
committed
try to set base path directly
1 parent a5f0594 commit 54346c0

3 files changed

Lines changed: 5 additions & 7 deletions

File tree

.github/workflows/static.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
BASE_PATH: '/${{ github.event.repository.name }}'
3939
run: |
4040
npm i
41-
npm run build
41+
npm run deploy
4242
touch dist/.nojekyll
4343
cp dist/index.html dist/404.html
4444
- name: Setup Pages

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@
66
"scripts": {
77
"dev": "vite",
88
"build": "vite build",
9-
"preview": "vite preview"
10-
},
9+
"preview": "vite preview",
10+
"deploy": "vite build --base=/code-struct-explorer/"
11+
},
1112
"devDependencies": {
1213
"@sveltejs/vite-plugin-svelte": "^5.0.3",
1314
"@types/cytoscape": "^3.21.9",

svelte.config.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,5 @@ import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'
33
export default {
44
// Consult https://svelte.dev/docs#compile-time-svelte-preprocess
55
// for more information about preprocessors
6-
preprocess: vitePreprocess(),
7-
paths: {
8-
base: process.argv.includes('dev') ? '' : '/code-struct-explorer'
9-
}
6+
preprocess: vitePreprocess()
107
}

0 commit comments

Comments
 (0)