Skip to content

Commit 54e0e8e

Browse files
committed
Use static server.
1 parent c916acf commit 54e0e8e

File tree

2 files changed

+4
-17
lines changed

2 files changed

+4
-17
lines changed

Dockerfile

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,6 @@ RUN yarn install --frozen-lockfile
1111
COPY . .
1212
RUN yarn build
1313

14-
# Create index.html for the SPA
15-
RUN printf '<!DOCTYPE html>\n\
16-
<html lang="en">\n\
17-
<head>\n\
18-
<meta charset="UTF-8">\n\
19-
<meta name="viewport" content="width=device-width, initial-scale=1.0">\n\
20-
<title>Teras - BlankOn</title>\n\
21-
<link rel="icon" href="/favicon.ico">\n\
22-
<link rel="manifest" href="/manifest.json">\n\
23-
<meta name="description" content="Teras - BlankOn Website">\n\
24-
</head>\n\
25-
<body>\n\
26-
<div id="root"></div>\n\
27-
<script type="module" src="/assets/main-_xEiGKjZ.js"></script>\n\
28-
</body>\n\
29-
</html>\n' > /app/dist/client/index.html
30-
3114
FROM nginx:alpine
3215

3316
# Copy static files from builder

vite.config.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ const config = defineConfig({
2222
tailwindcss(),
2323
tanstackStart({
2424
preset: 'static',
25+
prerender: {
26+
enabled: true,
27+
autoSubfolderIndex: true,
28+
},
2529
}),
2630
viteReact(),
2731
],

0 commit comments

Comments
 (0)