implementing-ios-code
БесплатноБез исполняемых скриптовНе проверенImplement, write code, add a new screen, create a feature, new view, new processor, or wire up a new service in Bitwarden iOS. Use when asked to "implement"…
от bitwarden★ 748 звёзд на GitHubОб этом скилле
Implementing iOS Code
Use this skill to implement Bitwarden iOS features following established patterns.
Prerequisites
- A plan should exist in
.claude/outputs/plans/<ticket-id>.md. If not, invokeplanning-ios-implementationfirst. - Read
Docs/Architecture.md— it is the authoritative source for all patterns. This skill references it, not replaces it.
Step 1: Determine Scope
From the plan, identify:
- Is this a new feature (full file-set) or modification of existing code?
- Which framework:
BitwardenShared,AuthenticatorShared, orBitwardenKit? - Which domain:
Auth/,Autofill/,Platform/,Tools/,Vault/?
See templates.md for file-set skeletons.
Step 2: Core Layer First
Implement from the bottom up:
Data Models (if needed)
- Request/Response types in
Core/<Domain>/Models/Request/andResponse/- Alphabetize stored properties and initializer parameters (parameters with default values go last). When you add one to an existing type, insert it at its alphabetical position and update the synthesized initializer and every call site to match — don't append.
- Enum types in
Core/<Domain>/Models/Enum/- Keep cases alphabetical. When you add a case to an existing enum, insert it at its alphabetical position in every
switchover that enum (across all layers) rather than appending it — match the surrounding order.
- Keep cases alphabetical. When you add a case to an existing enum, insert it at its alphabetical position in every
Persistence (if needed)
- Vault sync data → CoreData via
DataStore(add entities toBitwarden.xcdatamodeld) - Non-sensitive settings →
AppSettingsStore(backed by UserDefaults) - Credentials/keys →
KeychainRepository - All three are exposed through
StateService. Prefer adding a separate protocol over extendingStateService,AppSettingsStore, orKeychainRepositorydirectly, to maintain interface segregation.
Services / Repositories
- Define protocol with
// sourcery: AutoMockable - Implement
Default<Name>Service/Default<Name>Repository - Add
Has<Name>protocol - See
templates.mdfor service skeleton
Step 3: UI Layer (File-Set Pattern)
For new screens, create all required files together (see templates.md):
- Route — Add case to the parent Coordinator's route enum
- Coordinator — Navigation logic, screen instantiation,
Servicestypealias - State — Value type (
struct) holding all view-observable data - Action — Enum of user interactions handled synchronously in
receive(_:) - Effect — Enum of async work handled in
perform(_:) - Processor —
StateProcessorsubclass, business logic only - View — SwiftUI view using
store.binding,store.perform,@ObservedObject
SwiftUI previews:
- Use
#Previewmacros for new views — the modern default across the codebase. Do not add newPreviewProviderstructs. Because the snapshot harness cannot enumerate#Previewmacros, such a view's snapshot coverage comes from a test that instantiates the view directly; see thetesting-ios-codeskill for how to choose between that and iteratingPreviewProvider._allPreviewswhen a view exposes both.
New localization keys (BitwardenResources/.../Localizable.strings):
- Key name mirrors the English string:
Archivefor "Archive", notMoveToArchiveorArchiveTitle.- Exception: long descriptive strings (~70-80+ chars) use a
DescriptionLongsuffix on a shortened opening phrase. Example:PassphrasesAreOftenEasierToRememberDescriptionLong.
- Exception: long descriptive strings (~70-80+ chars) use a
- Translator-facing
/* … */comments describe meaning, placement, or constraints that affect translation — translators are the audience, not internal engineers.
Step 4: Wire Dependency Injection
After creating a new service/repository:
- Add
Has<Name>conformance toServiceContainervia extension - Add
Has<Name>to theServicestypealias of any processor that needs it
Step 5: Security Check
Before finishing:
- Vault data? → Must use
BitwardenSdkfor all encryption/decryption - Storing credentials? → Must use
KeychainRepository, notAppSettingsStore - User input? → Must validate via
InputValidator - Surfacing errors? → Sensitive errors must implement
NonLoggableError - Running in an extension? → Check Argon2id memory if KDF is involved
Step 6: Documentation
All new public types and methods require DocC (///) documentation.
Exceptions: protocol property/function implementations (docs live in the protocol), mock classes.
Use pragma marks to organize code. // MARK: - is used to denote different objects in the same file; // MARK: is used to denote different sections within an object.
Step 7: Verify — Lint, Format, and Regenerate
Run these checks after all code and tests are written, before handing back. Fix every violation found — do not leave warnings for the commit phase.
If new localization strings were added, regenerate first so SwiftGen picks them up:
mint run swiftgen config run --config swiftgen-bwr.yml # BitwardenResources (most common)
# Ru
Установить implementing-ios-code в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл implementing-ios-code?
Implement, write code, add a new screen, create a feature, new view, new processor, or wire up a new service in Bitwarden iOS. Use when asked to "implement", "write code", "add screen", "create feature", "new view", "new processor", "add service", or when translating a design doc into actual Swift code.
Как установить скилл implementing-ios-code?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл implementing-ios-code запускает скрипты?
Нет, скилл состоит только из инструкций (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