diff --git a/packages/playground/.gitignore b/packages/playground/.gitignore index 018675f..c82b321 100644 --- a/packages/playground/.gitignore +++ b/packages/playground/.gitignore @@ -1,3 +1,4 @@ /dist /test-results/ -/playwright-report/ \ No newline at end of file +/playwright-report/ +/build \ No newline at end of file diff --git a/packages/playground/devEnv/vite.config.ts b/packages/playground/devEnv/vite.config.ts index fcf3ede..8486841 100644 --- a/packages/playground/devEnv/vite.config.ts +++ b/packages/playground/devEnv/vite.config.ts @@ -20,6 +20,11 @@ const port = 8080 // https://vitejs.dev/config/ export default defineConfig({ root: path.join(playgroundDir, './src'), + build: { + outDir: '../build', + minify: false, + emptyOutDir: true, + }, assetsInclude: ['**/*.gltf', '**/*.glb'], server: { diff --git a/packages/playground/package.json b/packages/playground/package.json index b74ea35..a051400 100644 --- a/packages/playground/package.json +++ b/packages/playground/package.json @@ -9,6 +9,8 @@ ], "scripts": { "serve": "vite --config ./devEnv/vite.config.ts", + "build:static": "vite --config ./devEnv/vite.config.ts build", + "build:preview": "vite --config ./devEnv/vite.config.ts preview", "typecheck": "yarn run build", "test": "playwright test --config=devEnv/playwright.config.ts", "test:ci": "percy exec -- playwright test --reporter=dot --config=devEnv/playwright.config.ts --project=chromium", diff --git a/packages/playground/src/public/_redirects b/packages/playground/src/public/_redirects new file mode 100644 index 0000000..50a4633 --- /dev/null +++ b/packages/playground/src/public/_redirects @@ -0,0 +1 @@ +/* /index.html 200 \ No newline at end of file