import { Label } from '@/components/ui/label'; import { Switch } from '@/components/ui/switch'; import { Code2 } from 'lucide-react'; import { cn } from '@/lib/utils'; import { useAppStore, type ServerLogLevel } from '@/store/app-store'; import { toast } from 'sonner'; const LOG_LEVEL_OPTIONS: { value: ServerLogLevel; label: string; description: string }[] = [ { value: 'error', label: 'Error', description: 'Only show error messages' }, { value: 'warn', label: 'Warning', description: 'Show warnings and errors' }, { value: 'info', label: 'Info', description: 'Show general information (default)' }, { value: 'debug', label: 'Debug', description: 'Show all messages including debug' }, ]; // Check if we're in development mode const IS_DEV = import.meta.env.DEV; export function DeveloperSection() { const { serverLogLevel, setServerLogLevel, enableRequestLogging, setEnableRequestLogging, showQueryDevtools, setShowQueryDevtools, } = useAppStore(); return (
Advanced settings for debugging and development.
Control the verbosity of API server logs. Set to "Error" to only see error messages in the server console.
Log all HTTP requests (method, URL, status) to the server console.
Show React Query DevTools panel in the bottom-right corner for debugging queries and cache.