Skip to content

Commit 1810ae4

Browse files
fix: prevent copying public dir in public folder setups (fixes #47)
1 parent d2211c0 commit 1810ae4

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/node/index.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,12 @@ function getViteConfig(
6262
kirbyupGlobImportPlugin(),
6363
{ ...externalGlobals({ vue: 'Vue' }), enforce: 'post' },
6464
],
65-
css: { postcss: resolvedPostCssConfig },
65+
build: {
66+
copyPublicDir: false,
67+
},
68+
css: {
69+
postcss: resolvedPostCssConfig,
70+
},
6671
envPrefix: ['VITE_', 'KIRBYUP_'],
6772
customLogger: logger,
6873
logLevel,
@@ -96,8 +101,8 @@ function getViteConfig(
96101
const mode = options.watch ? 'development' : 'production'
97102

98103
const buildConfig: InlineConfig = mergeConfig(sharedConfig, {
99-
plugins: [kirbyupBuildCleanupPlugin(options as BuildOptions)],
100104
mode,
105+
plugins: [kirbyupBuildCleanupPlugin(options as BuildOptions)],
101106
build: {
102107
lib: {
103108
entry: resolve(options.cwd, options.entry),

0 commit comments

Comments
 (0)