Summary
Refactor API client to automatically wrap all API calls with loading spinners using a Proxy pattern.
Details
Port the API Spinner Proxy pattern from todoist-cli:
- Define spinner messages per API method in a config object
- Use JavaScript
Proxy to intercept API calls and wrap them with spinners automatically
- Remove manual spinner wrapping from individual calls
Current State
outline-cli already has SPINNER_MESSAGES mapping in api.ts but wraps each call manually.
Benefits
- Cleaner API wrapper code
- Automatic spinner management
- Easier to add new endpoints
Effort
1 day
Reference
Based on todoist-cli pattern in src/lib/api/core.ts
Summary
Refactor API client to automatically wrap all API calls with loading spinners using a Proxy pattern.
Details
Port the API Spinner Proxy pattern from todoist-cli:
Proxyto intercept API calls and wrap them with spinners automaticallyCurrent State
outline-cli already has
SPINNER_MESSAGESmapping inapi.tsbut wraps each call manually.Benefits
Effort
1 day
Reference
Based on todoist-cli pattern in
src/lib/api/core.ts