angular-http-client
БесплатноБез исполняемых скриптовНе проверенIntegrate HttpClient, Interceptors, and API interactions in Angular. Use when integrating HttpClient, writing interceptors, or handling API calls in Angular.
от HoangNguyen0403★ 598 звёзд на GitHubОб этом скилле
HTTP Client
Priority: P1 (HIGH)
Principles
- Functional Interceptors: Use HttpInterceptorFn (e.g.,
(req, next) => next(req.clone({ setHeaders: { Authorization: token } }))). Clone requests withreq.clone(— class-based interceptors deprecated. Register via withInterceptors([...]) in provideHttpClient. - Typed Responses: Always type
http.post<T>(),http.get<T>(). Useinject(HttpClient)in services (not constructor injection). Add provideHttpClient(withInterceptors([...]), withFetch()) toapp.config.ts. - Services: Encapsulate all HTTP calls in Services. Never call
httpin Components.
Signal-Based HTTP (Angular 17+)
Prefer httpResource
// Reactive: refetches automatically when userId() changes
userResource = httpResource<User>(() => `/api/users/${this.userId()}`);
// States: .isLoading() | .hasValue() | .error() | .value() | .reload()
Use resource<T, P>({ request: () => params(), loader: ... }) for non-HTTP async operations with full .isLoading() lifecycle control.
Guidelines
- Caching: Implement caching in interceptors or using
shareReplay(1)in services. - Error Handling: Handle errors in service using
catchErroror global interceptors, not components. Use notification service for display. - Context: Use HttpContext to pass metadata to interceptors (e.g., skip error handling or specific caching rules).
Anti-Patterns
- No HTTP in Components: Encapsulate all HTTP calls in Services.
- No class-based interceptors: Use
HttpInterceptorFnfunctional interceptors. - No manual subscribe for GET: Use httpResource() or
toSignal(http.get(...))instead.
References
Установить angular-http-client в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл angular-http-client?
Integrate HttpClient, Interceptors, and API interactions in Angular. Use when integrating HttpClient, writing interceptors, or handling API calls in Angular.
Как установить скилл angular-http-client?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл angular-http-client запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
doc-coauthoring
Guide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
от Anthropicacademy-guide
Stop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
от Anthropicinternal-comms
A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
от Anthropicskill-development
This skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…
от Anthropic