Localization Setup
rshankras/claude-code-apple-skills
Generate internationalization (i18n) infrastructure for multi-language support in iOS/macOS apps.
A skill your agent uses when building iOS/macOS apps with SwiftUI — covers localization (String Catalogs), date/time formatting, JSON date decoding, Previews, state management, sheet/navigation…
$ npx skills add hanamizuki/solopreneur --skill ios-patterns -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install hanamizuki/solopreneur ios-patterns --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/hanamizuki/solopreneur.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/ios-dev/ios-patterns .claude/skills/ios-patterns && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "ios-patterns" agent skill from https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patterns into .claude/skills/ios-patterns/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "ios-patterns", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patternsType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add hanamizuki/solopreneur --skill ios-patterns -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install hanamizuki/solopreneur ios-patterns --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/hanamizuki/solopreneur.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/ios-dev/ios-patterns .agents/skills/ios-patterns && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "ios-patterns" agent skill from https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patterns into .agents/skills/ios-patterns/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "ios-patterns", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add hanamizuki/solopreneur --skill ios-patterns -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install hanamizuki/solopreneur ios-patterns --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/hanamizuki/solopreneur.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/ios-dev/ios-patterns .cursor/skills/ios-patterns && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "ios-patterns" agent skill from https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patterns into .cursor/skills/ios-patterns/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "ios-patterns", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/hanamizuki/solopreneur.git --path skills/ios-dev/ios-patterns--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add hanamizuki/solopreneur --skill ios-patterns -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install hanamizuki/solopreneur ios-patterns --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/hanamizuki/solopreneur.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/ios-dev/ios-patterns .gemini/skills/ios-patterns && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "ios-patterns" agent skill from https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patterns into .gemini/skills/ios-patterns/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "ios-patterns", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install hanamizuki/solopreneur ios-patternsInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add hanamizuki/solopreneur --skill ios-patterns -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/hanamizuki/solopreneur.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/ios-dev/ios-patterns .github/skills/ios-patterns && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "ios-patterns" agent skill from https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patterns into .github/skills/ios-patterns/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "ios-patterns", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add hanamizuki/solopreneur --skill ios-patterns -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install hanamizuki/solopreneur ios-patterns --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/hanamizuki/solopreneur.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/ios-dev/ios-patterns .opencode/skills/ios-patterns && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "ios-patterns" agent skill from https://github.com/hanamizuki/solopreneur/tree/main/skills/ios-dev/ios-patterns into .opencode/skills/ios-patterns/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "ios-patterns", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
ios-patternsA skill your agent uses when building iOS/macOS apps with SwiftUI — covers localization (String Catalogs), date/time formatting, JSON date decoding, Previews, state management, sheet/navigation…
iOS Patterns is an agent skill from hanamizuki/solopreneur. Use when building iOS/macOS apps with SwiftUI — covers localization (String Catalogs), date/time formatting, JSON date decoding, Previews, state management, sheet/navigation, list spacing, and animation patterns.
Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including reference files (for example `references/i18n-guide.md` and `references/swiftui-preview-guide.md`).
It sits in Frontend & Design, covering Internationalization, iOS development and State management. It works with iOS, SwiftUI and macOS. The repository describes itself as: Skills and agents for solopreneurs — ship, review, debug, and think through problems with AI. The licence is MIT.
10 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit f43f001. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
ReadWriteEditBashGrepGlobFrom allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are swift).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
iOS Patterns loads about 2.3k tokens when it runs, and up to ~3.8k if it reads all its reference files. Until then it costs about 56 tokens; SKILL.md has 470 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
allowed-tools: Read, Write, Edit, Bash, Grep, GlobAutomated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from hanamizuki/solopreneur at commit f43f001, republished under its MIT licence (© hanamizuki). 470 words, ~2,329 tokens.
.claude/skills/ios-patterns/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.A collection of SwiftUI conventions that keep code consistent, localizable,
and resilient to edge cases. Apply these patterns to any iOS/macOS SwiftUI
project. See references/ for in-depth guides.
Use String Catalog (.xcstrings) — not Localizable.strings — for all
user-facing text. Reference: references/i18n-guide.md.
// In a View: LocalizedStringKey is inferred
Text("welcome_message")
Text("greeting \(username)")
// In a ViewModel or non-View context, use String(localized:)
let message = String(localized: "error_network")
let formatted = String(localized: "items_count \(count)")Use snake_case, grouped by feature: home_title, settings_notification_enabled,
error_network_unavailable. Embed parameters in the key:
"profile_welcome \(name)", "cart_items_count \(count)".
Text("Welcome") // ❌ hard-coded
let title: LocalizedStringKey = "welcome" // ❌ only works in Views
let title = String(localized: "welcome") // ✅ works anywhereNever hard-code format strings like "M/d" or "MM/dd". Different locales
order date components differently (US: 12/13, AU/UK: 13/12, TW: 12/13).
Use setLocalizedDateFormatFromTemplate so the system picks the correct order.
Centralize formatting behind one utility (e.g. LocalizedDateFormatter) that
vends cached DateFormatters keyed by template:
enum LocalizedDateStyle {
case monthDayNumeric // "Md" → 12/13 or 13/12
case monthDayAbbreviated // "MMMd" → Dec 13 / 13 Dec / 12月13日
case yearMonthDayAbbreviated // "yMMMd" → Dec 13, 2025
case yearMonthDayFull // "yMMMMd" → December 13, 2025
// ...
}
let text = LocalizedDateFormatter.string(from: date, style: .monthDayAbbreviated)Locale (e.g. zh-Hant vs zh-Hans)
so Traditional and Simplified Chinese users see the right format.DateFormatter is not thread-safe — shared cached formatters are main-thread
only. Background threads must create their own instance.yyyy-MM-dd, HH:mm) — not localized.JSONDecoder.DateDecodingStrategy.iso8601 does not accept fractional seconds.
Backends (PostgreSQL timestamptz, Supabase, Fider, etc.) may return any of:
2025-12-08T10:00:00Z ✅ supported
2025-12-08T10:00:00.123Z ❌ fails
2025-12-08T10:00:00.123456Z ❌ failsThe bug is data-dependent and intermittent — local fixtures usually don't reproduce it. Always install a flexible decoder:
extension JSONDecoder {
static var withFlexibleDateDecoding: JSONDecoder {
let decoder = JSONDecoder()
decoder.dateDecodingStrategy = .custom { decoder in
let container = try decoder.singleValueContainer()
let s = try container.decode(String.self)
let f = ISO8601DateFormatter()
f.formatOptions = [.withInternetDateTime, .withFractionalSeconds]
if let d = f.date(from: s) { return d }
f.formatOptions = [.withInternetDateTime]
if let d = f.date(from: s) { return d }
// Normalize PostgreSQL "yyyy-MM-dd HH:mm:ss.SSSSSS" → ISO8601
let normalized = s
.replacingOccurrences(of: " ", with: "T")
.replacingOccurrences(of: #"(\.\d{3})\d+"#, with: "\$1",
options: .regularExpression)
f.formatOptions = [.withInternetDateTime, .withFractionalSeconds]
if let d = f.date(from: normalized) { return d }
throw DecodingError.dataCorruptedError(
in: container,
debugDescription: "Unrecognized date format: \(s)")
}
return decoder
}
}Every View ships with Previews. Reference: references/swiftui-preview-guide.md.
#Preview("Default") { MyView() }
#Preview("With Data") { MyView(items: .mock) }
#Preview("Empty State") { MyView(items: []) }
#Preview("Dark Mode") {
MyView().preferredColorScheme(.dark)
}
#Preview("Large Text") {
MyView().environment(\.dynamicTypeSize, .accessibility3)
}
#Preview("繁體中文") {
MyView().environment(\.locale, .init(identifier: "zh-Hant"))
}Provide mock static values on models so Previews stay trivial:
extension User {
static let mock = User(id: UUID(), name: "Alice", email: "a@example.com")
static let mockList: [User] = [.mock, /* ... */]
}@State private var isExpanded = false // local view state
@Binding var selectedItem: Item? // mutable state from parent
@StateObject private var vm = MyViewModel() // owner of a VM
@ObservedObject var vm: MyViewModel // passed-in VM
@Environment(\.dismiss) private var dismiss@MainActor
final class MyViewModel: ObservableObject {
@Published private(set) var items: [Item] = []
@Published private(set) var isLoading = false
@Published var error: Error?
func loadItems() async {
isLoading = true
defer { isLoading = false }
do { items = try await service.fetchItems() }
catch { self.error = error }
}
}Apply modifiers in a consistent order: content style → size → padding → background → shape → shadow → gesture.
Text("Hello")
.font(.headline)
.frame(maxWidth: .infinity)
.padding()
.background(.blue)
.cornerRadius(8)
.shadow(radius: 4)
.onTapGesture { }Pick the sheet configuration by purpose:
| Kind | Detents | Drag indicator | Dismissable by swipe |
|---|---|---|---|
| Info (short explanation) | [.fraction(0.3–0.5)] | visible | yes |
| Content (detail view) | [.medium, .large] | visible | yes |
| Management (data list) | [.medium, .large] | visible | yes |
| Edit (form with unsaved input) | default or .large | hidden | no — .interactiveDismissDisabled() |
// Edit sheet — must commit via explicit Save/Cancel
.sheet(isPresented: $showEdit) {
EditFormView(onSave: save, onCancel: { showEdit = false })
.interactiveDismissDisabled()
}NavigationStack.NavigationStack.NavigationStack; prefer multiple sheets over
nested sheet navigation. Avoid stacking sheets more than 2 levels deep.When a Section has a footer, set .listSectionSpacing(.custom(24)) so the
small footer text isn't crammed against the next section:
Section {
TextField("name", text: $name)
} header: {
Text("basic_info")
} footer: {
Text("basic_info_hint")
}
.listSectionSpacing(.custom(24))Individual Section settings override a Form-level .listSectionSpacing(...).
Inside Form/List, conditionally rendering content with if isExpanded { ... }
causes the whole list to reflow and the content to slide in from above,
overlapping the first row.
Fix: always render; toggle frame(maxHeight:) and opacity:
VStack(alignment: .leading, spacing: 8) {
Button { isExpanded.toggle() } label: {
HStack { Text("title"); Spacer(); Text(isExpanded ? "less" : "more") }
}
.buttonStyle(.plain)
Text("expanded_body_copy")
.fixedSize(horizontal: false, vertical: true)
.frame(maxHeight: isExpanded ? nil : 0, alignment: .top)
.opacity(isExpanded ? 1 : 0)
.clipped()
}
.animation(.easeInOut(duration: 0.15), value: isExpanded)Keep .animation(_:value:) on the container — don't wrap the toggle in
withAnimation. For simple disclosure UI, prefer the built-in DisclosureGroup.
All keyboard-input screens should share one "Done" affordance. Implement it
once as a ViewModifier using safeAreaInset(edge: .bottom) — it is more
reliable than .toolbar(placement: .keyboard), which has a known iOS 18 bug
where the toolbar fails to appear on first focus.
// ✅ Apply to the outermost container (NavigationStack / Form)
NavigationStack {
Form {
TextField("name", text: $name)
TextField("amount", value: $amount, formatter: .decimal)
}
}
.keyboardDoneButton()
// ✅ Run extra logic on dismiss
.keyboardDoneButton(onDone: { focusedField = nil })references/i18n-guide.md — String Catalog workflow, pluralization, testingreferences/swiftui-preview-guide.md — Preview patterns, providers, device matrices© hanamizuki, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 2 other files (references) in skills/ios-dev/ios-patterns of hanamizuki/solopreneur.
Open the folder on GitHubat commit f43f001
iOS Patterns next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| iOS Patterns this skillhanamizuki/solopreneur | 152 | — | ~2.3k | Automated safety check: Notes | MIT | |
| Localization Setuprshankras/claude-code-apple-skills | 783 | — | ~1.4k | Automated safety check: Notes | MIT | |
| Swiftui Patternsaffaan-m/ECC | 275k | 4 repos | ~1.8k | Automated safety check: Pass | MIT | |
| Xcstrings ManagerEslzzyl/Pixiv-SwiftUI | 111 | — | ~482 | Automated safety check: Pass | AGPL-3.0 | |
| Swiftui Expert Skillsupabitapp/supaterm | 172 | — | ~1.5k | Automated safety check: Pass | Custom licence | |
| Hig Project Contextraintree-technology/hig-doctor | 143 | 5 repos | ~1.2k | Automated safety check: Pass | MIT |
rshankras/claude-code-apple-skills
Generate internationalization (i18n) infrastructure for multi-language support in iOS/macOS apps.
affaan-m/ECC
SwiftUI architecture patterns, state management with @Observable, view composition, navigation, performance optimization, and modern iOS/macOS UI best practices.
Eslzzyl/Pixiv-SwiftUI
Manage Xcode String Catalog (.xcstrings) localization files through a command-line interface.
supabitapp/supaterm
Write, review, or improve SwiftUI code following best practices for state management, view composition, performance, macOS-specific APIs, and iOS 26+ Liquid Glass adoption.
raintree-technology/hig-doctor
Create or update a shared Apple design context document that other HIG skills use to tailor guidance.
raintree-technology/hig-doctor
Apple Human Interface Guidelines for content display components.
hanamizuki/solopreneur
Create an interactive HTML preview of any proposal, plan, idea, doc, brief, or spec and land it in the browsable local Preview Library by default (opens under file:// with a catalog sidebar and…
hanamizuki/solopreneur
LinkedIn organic growth consultant — diagnoses profiles, discusses goals, and co-creates a personalized 90-day growth plan.
hanamizuki/solopreneur
Switch perspectives to think through problems using the mental models of ten iconic thinkers: Elon Musk, Richard Feynman, Charlie Munger, Naval Ravikant, Steve Jobs, Nassim Taleb, Ilya Sutskever…
hanamizuki/solopreneur
Create brand-aware presentations using frontend-slides or reveal.js.
hanamizuki/solopreneur
X/Twitter growth consultant — diagnoses profiles, discusses goals, and co-creates a personalized growth plan.
hanamizuki/solopreneur
X/Twitter writing coach — helps you write single tweets, threads, and long-form posts.
Categories
A skill your agent uses when building iOS/macOS apps with SwiftUI — covers localization (String Catalogs), date/time formatting, JSON date decoding, Previews, state management, sheet/navigation…. iOS Patterns is an agent skill from hanamizuki/solopreneur. Use when building iOS/macOS apps with SwiftUI — covers localization (String Catalogs), date/time formatting, JSON date decoding, Previews, state management, sheet/navigation, list spacing, and animation patterns.
iOS Patterns fits situations like: building iOS/macOS apps with SwiftUI — covers localization (String Catalogs); date/time formatting; JSON date decoding; state management.
Run `npx skills add hanamizuki/solopreneur --skill ios-patterns -a claude-code`. Or copy the skill folder (skills/ios-dev/ios-patterns in hanamizuki/solopreneur) into .claude/skills/ios-patterns in your project. Claude Code loads it when a task matches its description.
Run `npx skills add hanamizuki/solopreneur --skill ios-patterns -a codex`. Or copy the skill folder (skills/ios-dev/ios-patterns in hanamizuki/solopreneur) into .agents/skills/ios-patterns in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add hanamizuki/solopreneur --skill ios-patterns -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/ios-patterns, .gemini/skills/ios-patterns, .github/skills/ios-patterns and .opencode/skills/ios-patterns in your project.
SKILL.md names no scripts, command-line tools or credentials: iOS Patterns is instructions for the agent only. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash, Grep, Glob.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.
iOS Patterns is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.3k tokens (SKILL.md is roughly 9.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1.5k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with iOS Patterns: Localization Setup (rshankras/claude-code-apple-skills, 783 stars), Swiftui Patterns (affaan-m/ECC, 275k stars), Xcstrings Manager (Eslzzyl/Pixiv-SwiftUI, 111 stars) and Swiftui Expert Skill (supabitapp/supaterm, 172 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
hanamizuki (a GitHub user) maintains it in hanamizuki/solopreneur, which has 152 GitHub stars. The repository holds 31 skills in this directory. The repository was last updated on September 26, 2026.
Source: hanamizuki/solopreneur on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.