Skip to content

Commit b85ef17

Browse files
raifdmuellerclaude
andcommitted
refactor: make pre-rendering opt-in via npm run build:prerender
Puppeteer setup in GitHub Actions CI is complex (Chrome dependencies, executable paths, etc.). Instead of fighting CI, make pre-rendering opt-in for local builds before releases. Changes: - npm run build → standard SPA build (no pre-rendering) - npm run build:prerender → build + Puppeteer pre-rendering - Removed Chrome setup from deploy.yml workflow - Keep PUPPETEER_SKIP_DOWNLOAD=true in CI (faster installs) - Added README.md with pre-rendering instructions Rationale: - CI deploys standard SPA (Google/Bing will index via JS execution) - Pre-rendered builds can be done locally before important releases - Avoids CI complexity and fragility - Still have SEO meta tags for immediate indexing Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent c810d9c commit b85ef17

3 files changed

Lines changed: 47 additions & 9 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,6 @@ jobs:
3232
env:
3333
PUPPETEER_SKIP_DOWNLOAD: true
3434

35-
- name: Setup Chrome for Puppeteer
36-
uses: browser-actions/setup-chrome@latest
37-
with:
38-
chrome-version: stable
39-
40-
- name: Set Puppeteer executable path
41-
run: echo "PUPPETEER_EXECUTABLE_PATH=$(which google-chrome-stable)" >> $GITHUB_ENV
42-
4335
- name: Detect base path
4436
id: base
4537
run: |

README.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Vibe-Coding Risk Radar
2+
3+
MECE risk framework for AI-generated code — 5 dimensions, 4 tiers, actionable mitigations.
4+
5+
🔗 **Live Demo:** https://llm-coding.github.io/vibe-coding-risk-radar/
6+
7+
## Features
8+
9+
- Interactive 5-dimension risk assessment (code type, language, deployment, data, blast radius)
10+
- 4-tier classification (Minimal, Moderate, High, Critical)
11+
- Claude Code skills for automated repo analysis (`/risk-assess`, `/risk-mitigate`)
12+
- Architecture Decision Record (ADR) generation
13+
- Bilingual interface (DE/EN)
14+
15+
## Development
16+
17+
```bash
18+
npm install # Install dependencies
19+
npm run dev # Start dev server
20+
npm run build # Production build
21+
npm run preview # Preview build locally
22+
```
23+
24+
## Pre-rendering for SEO
25+
26+
The app includes a Puppeteer-based pre-rendering script for better SEO.
27+
28+
**Local pre-rendering (before release):**
29+
30+
```bash
31+
npm run build:prerender
32+
```
33+
34+
This renders the full React app to static HTML in `dist/index.html`.
35+
36+
**Note:** Pre-rendering is not run in CI due to Puppeteer/Chrome setup complexity. The deployed version is a standard SPA (search engines with JS support will still index it, just slower).
37+
38+
## Documentation
39+
40+
- Full docs: `npm run docs``dist/docs/`
41+
- In-app: Click "Documentation" button
42+
43+
## License
44+
45+
MIT — see LICENSE file

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
"type": "module",
66
"scripts": {
77
"dev": "vite",
8-
"build": "vite build && node scripts/prerender.js",
8+
"build": "vite build",
9+
"build:prerender": "npm run build && node scripts/prerender.js",
910
"preview": "vite preview",
1011
"docs": "asciidoctor -a icons=font -a source-highlighter=highlight.js -a linkcss -a stylesheet=asciidoctor.css -D dist/docs docs/risk-radar.adoc docs/risk-radar-en.adoc",
1112
"prepare": "husky"

0 commit comments

Comments
 (0)