Refactor code structure and remove redundant changes

This commit is contained in:
pacnpal
2025-11-09 16:31:34 -05:00
parent 2884bc23ce
commit eb68cf40c6
1080 changed files with 27361 additions and 56687 deletions

View File

@@ -0,0 +1,37 @@
/**
* Temporary test component to verify error logging system
* Delete this file after testing
*/
import { Button } from '@/components/ui/button';
import { handleError } from '@/lib/errorHandler';
import { supabase } from '@/lib/supabaseClient';
import { useAuth } from '@/hooks/useAuth';
export function TestErrorLogging() {
const { user } = useAuth();
const testError = () => {
try {
throw new Error('Test error for logging system verification');
} catch (error) {
handleError(error, {
action: 'Test Error Logging',
userId: user?.id,
metadata: { test: true }
});
}
};
const testApiCall = async () => {
// This will generate breadcrumbs via the wrapped client
await supabase.from('parks').select('id').limit(1);
};
return (
<div className="p-4 space-y-4">
<h2 className="text-xl font-bold">Error Logging Test</h2>
<Button onClick={testError}>Generate Test Error</Button>
<Button onClick={testApiCall} variant="outline">Test API Breadcrumbs</Button>
</div>
);
}