File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 37
37
- name : Upload artifact
38
38
uses : actions/upload-pages-artifact@v1
39
39
with :
40
- path : ./build
40
+ path : ./build/eslint-plugin-svelte
41
41
- name : Deploy to GitHub Pages
42
42
id : deployment
43
43
uses : actions/deploy-pages@v1
Original file line number Diff line number Diff line change @@ -19,6 +19,8 @@ fs.writeFileSync(
19
19
JSON . stringify ( { type : "module" } ) ,
20
20
)
21
21
22
+ const outDir = path . join ( dirname , "build/eslint-plugin-svelte" )
23
+
22
24
/** @type {import('@sveltejs/kit').Config } */
23
25
const config = {
24
26
compilerOptions : {
@@ -31,8 +33,8 @@ const config = {
31
33
} ,
32
34
adapter : ghpagesAdapter ( {
33
35
// default options are shown
34
- pages : "build" ,
35
- assets : "build" ,
36
+ pages : outDir ,
37
+ assets : outDir ,
36
38
} ) ,
37
39
prerender : {
38
40
default : true ,
Original file line number Diff line number Diff line change @@ -65,6 +65,13 @@ const config: UserConfig = {
65
65
acorn : path . join ( dirname , "./node_modules/acorn/dist/acorn.js" ) ,
66
66
} ,
67
67
} ,
68
+ ssr : {
69
+ // vite-plugin-svelte recognizes svelte-eslint-parser as a library that runs on svelte.
70
+ // This confuses the SSR on the Dev server.
71
+ // This is the workaround for that.
72
+ // https://github.com/sveltejs/vite-plugin-svelte/blob/a1d141e890ac0d1572a46e2bec705aa090236560/packages/vite-plugin-svelte/src/utils/dependencies.ts#L114
73
+ external : [ "svelte-eslint-parser" ] ,
74
+ } ,
68
75
build : {
69
76
commonjsOptions : {
70
77
ignoreDynamicRequires : true ,
You can’t perform that action at this time.
0 commit comments