scoring-event.ts exported getEventTypeLabel, a pure display helper used directly in route components, from the same module that imports scoring-calculator.ts (which now pulls in the Discord notification service, a .server-only module). Because that whole chain was value-imported into the client bundle, Vite's server-only-module guard failed the build. Move getEventTypeLabel into a new client-safe scoring-event-types.ts module with no server dependencies, and import it directly where it's rendered. |
||
|---|---|---|
| .. | ||
| components | ||
| contexts | ||
| hooks | ||
| lib | ||
| models | ||
| routes | ||
| services | ||
| test | ||
| types | ||
| utils | ||
| welcome | ||
| app.css | ||
| entry.client.tsx | ||
| entry.server.tsx | ||
| root.tsx | ||
| routes.ts | ||