Skip to content

Commit 09def56

Browse files
FluxStack Teamclaude
andcommitted
fix: resolve TypeScript warnings and add clean dev mode
- Fix 40+ TypeScript unused import/variable warnings across codebase - Add run-clean.ts wrapper to filter Elysia HEAD request errors - Add dev:clean command for development with filtered output - Update bun.lock with latest dependencies - Export missing interfaces in monitoring and config modules - Prefix intentionally unused parameters with underscore - Update documentation with new dev:clean command 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 5f246e6 commit 09def56

File tree

27 files changed

+947
-54
lines changed

27 files changed

+947
-54
lines changed

CLAUDE.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,7 @@ bun install # Uma única instalação para todo o projeto! 🎉
172172
### Comandos Principais
173173
```bash
174174
bun run dev # ✅ Full-stack: Backend (3000) + Vite integrado (5173)
175+
bun run dev:clean # ✅ Servidor com output limpo (filtra erros HEAD do Elysia)
175176
bun run dev:backend # ✅ Backend apenas com hot reload (porta 3001)
176177
bun run dev:frontend # ✅ Frontend apenas com Vite (porta 5173)
177178
bun run build # Build para produção
@@ -227,6 +228,7 @@ bun run legacy:dev # Comando direto com Bun watch (alternativo)
227228
-**Estrutura de instalação complexa** -> unificado em monorepo
228229
-**Duplicação de dependências** -> centralizadas no root
229230
-**Build em 2 etapas** -> processo unificado e otimizado
231+
-**Spam de erros HEAD do Elysia** -> comando `dev:clean` filtra erros desnecessários
230232

231233
## Próximos Passos Sugeridos
232234

@@ -252,6 +254,7 @@ bun install
252254

253255
# Desenvolvimento
254256
bun run dev # Full-stack development server
257+
bun run dev:clean # Servidor com output limpo (sem erros HEAD)
255258
bun run dev:frontend # Frontend apenas (porta 5173)
256259
bun run dev:backend # Backend apenas (porta 3001)
257260

bun.lock

Lines changed: 877 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bun.lockb

-155 KB
Binary file not shown.

core/__tests__/integration.test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
import { describe, it, expect, beforeEach, afterEach, vi } from 'vitest'
77
import { FluxStackFramework } from '../framework/server'
88
import { PluginRegistry } from '../plugins/registry'
9-
import { loggerPlugin } from '../plugins/built-in/logger'
109
import { logger } from '../utils/logger'
1110
import type { Plugin } from '../plugins/types'
1211

core/build/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { spawn } from "bun"
2-
import { join } from "path"
32
import type { FluxStackConfig } from "../config"
43

54
export class FluxStackBuilder {

core/client/standalone.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
// Standalone frontend development
22
import { spawn } from "bun"
33
import { join } from "path"
4-
import { getEnvironmentInfo } from "../config/env"
54

65
export const startFrontendOnly = (config: any = {}) => {
76
const clientPath = config.clientPath || "app/client"

core/config/loader.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,7 @@
66
import { existsSync } from 'fs'
77
import { join } from 'path'
88
import type {
9-
FluxStackConfig,
10-
LogLevel,
11-
BuildTarget,
12-
LogFormat
9+
FluxStackConfig
1310
} from './schema'
1411
import {
1512
defaultFluxStackConfig,
@@ -319,7 +316,7 @@ function findConfigFile(startDir = process.cwd()): string | null {
319316
/**
320317
* Apply environment-specific configuration
321318
*/
322-
function applyEnvironmentConfig(
319+
export function applyEnvironmentConfig(
323320
config: FluxStackConfig,
324321
environment: string
325322
): FluxStackConfig {

core/framework/__tests__/server.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ vi.mock('elysia', () => ({
5555
options: vi.fn().mockReturnThis(),
5656
onError: vi.fn().mockReturnThis(),
5757
use: vi.fn().mockReturnThis(),
58-
listen: vi.fn((port, callback) => {
58+
listen: vi.fn((_port, callback) => {
5959
if (callback) callback()
6060
})
6161
}))

core/framework/server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ export class FluxStackFramework {
5252
}
5353
return result
5454
},
55-
validateSchema: (data: any, schema: any) => {
55+
validateSchema: (_data: any, _schema: any) => {
5656
// Simple validation - in a real implementation you'd use a proper schema validator
5757
try {
5858
// Basic validation logic

core/plugins/__tests__/manager.test.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
import { describe, it, expect, beforeEach, vi, afterEach } from 'vitest'
66
import { PluginManager } from '../manager'
7-
import type { Plugin, PluginContext, RequestContext } from '../types'
7+
import type { Plugin, PluginContext } from '../types'
88
import type { Logger } from '../../utils/logger/index'
99
import type { FluxStackConfig } from '../../config/schema'
1010

@@ -327,12 +327,10 @@ describe('PluginManager', () => {
327327
})
328328

329329
it('should provide plugin-specific logger', async () => {
330-
let pluginLogger: any
331-
332330
const plugin: Plugin = {
333331
name: 'logger-plugin',
334-
setup: (context) => {
335-
pluginLogger = context.logger
332+
setup: (_context) => {
333+
// Logger context is available but not used in this test
336334
}
337335
}
338336

0 commit comments

Comments
 (0)