# common-pitfalls > Apply when debugging errors, reviewing code for issues, or encountering unexpected behavior. Contains known mistakes with ChurchTools API, Vue components, TypeScript, Safari cookies, and form handling. - Author: Bernhard Weichel - Repository: bwl21/bwl-flyer-generator - Version: 20260106180531 - Stars: 0 - Forks: 0 - Last Updated: 2026-02-07 - Source: https://github.com/bwl21/bwl-flyer-generator - Web: https://mule.run/skillshub/@@bwl21/bwl-flyer-generator~common-pitfalls:20260106180531 --- --- name: common-pitfalls description: Apply when debugging errors, reviewing code for issues, or encountering unexpected behavior. Contains known mistakes with ChurchTools API, Vue components, TypeScript, Safari cookies, and form handling. --- # Common Pitfalls ## ChurchTools API | Pitfall | Wrong | Correct | |---------|-------|---------| | Nested params | `{ params: { key: 'val' } }` | `{ key: 'val' }` | | Delete method | `churchtoolsClient.delete()` | `churchtoolsClient.deleteApi()` | | Tags response | `response.data` | `response` (direct array) | | Tag domains | `'appointment'` | `'person' \| 'song' \| 'group'` | ## Vue Components | Pitfall | Wrong | Correct | |---------|-------|---------| | Button type | ` ``` ## API Error Handling Always wrap API calls in try-catch with loading states: ```typescript try { loading.value = true // API call } catch (err) { error.value = 'User-friendly message' console.error('Debug info:', err) } finally { loading.value = false } ```