agent-transcript
Requested GitHub PR/issue agent transcripts: redact, trim, preview, and insert safely.
SwiftUI view refactor/review: layout, DI, Observation, view models.
Claude Code
$ npx -y skills add steipete/agent-scripts --skill swiftui-view-refactor --agent claude-code
Codex
$ npx skills add steipete/agent-scripts --skill swiftui-view-refactor -a codex -y
Cursor
$ npx skills add steipete/agent-scripts --skill swiftui-view-refactor -a cursor -y
Gemini CLI
$ npx skills add steipete/agent-scripts --skill swiftui-view-refactor -a gemini-cli -y
GitHub Copilot
$ npx skills add steipete/agent-scripts --skill swiftui-view-refactor -a github-copilot -y
OpenCode
$ npx skills add steipete/agent-scripts --skill swiftui-view-refactor -a opencode -y
Windsurf
$ npx skills add steipete/agent-scripts --skill swiftui-view-refactor -a windsurf -y
name: swiftui-view-refactor description: "SwiftUI view refactor/review: layout, DI, Observation, view models."
_Attribution: copied from @Dimillian’s `Dimillian/Skills` (2025-12-31)._
Apply a consistent structure and dependency pattern to SwiftUI views, with a focus on ordering, Model-View (MV) patterns, careful view model handling, and correct Observation usage.
Example (extracting a section):
var body: some View {
VStack(alignment: .leading, spacing: 16) {
HeaderSection(title: title, isPinned: isPinned)
DetailsSection(details: details)
ActionsSection(onSave: onSave, onCancel: onCancel)
}
}Example (long body → shorter body + computed views in the same file):
var body: some View {
List {
header
filters
results
footer
}
}
private var header: some View {
VStack(alignment: .leading, spacing: 6) {
Text(title).font(.title2)
Text(subtitle).font(.subheadline)
}
}
private var filters: some View {
ScrollView(.horizontal, showsIndicators: false) {
HStack {
ForEach(filterOptions, id: \.self) { option in
FilterChip(option: option, isSelected: option == selectedFilter)
.onTapGesture { selectedFilter = option }
}
}
}
}Example (extracting a complex computed view):
private var header: some View {
HeaderSection(title: title, subtitle: subtitle, status: status)
}
private struct HeaderSection: View {
let title: String
let subtitle: String?
let status: Status
var body: some View {
VStack(alignment: .leading, spacing: 4) {
Text(title).font(.headline)
if let subtitle { Text(subtitle).font(.subheadline) }
StatusBadge(status: status)
}
}
}Example (Observation-based):
@State private var viewModel: SomeViewModel
init(dependency: Dependency) {
_viewModel = State(initialValue: SomeViewModel(dependency: dependency))
}1) Reorder the view to match the ordering rules. 2) Favor MV: move lightweight orchestration into the view using `@State`, `@Environment`, `@Query`, `task`, and `onChange`. 3) If a view model exists, replace optional view models with a non-optional `@State` view model initialized in `init` by passing dependencies from the view. 4) Confirm Observation usage: `@State` for root `@Observable` view models, no redundant wrappers. 5) Keep behavior intact: do not change layout or business logic unless requested.
Shared agent instructions, skills, and small portable helpers for Peter's local workspaces.
Requested GitHub PR/issue agent transcripts: redact, trim, preview, and insert safely.
Beeper cache: contact hints, room lookup, WhatsApp/iMessage traces, FTS.
Control the user's existing signed-in Chrome: callable Codex Chrome plugin first, then OpenClaw extension-backed mcporter, with…
ClawSweeper status: URLs, workflow health, active workers, ops snapshot.
ClickClack ops: chat app, Cloudflare Workers deploy, DNS/docs/app, container rollout.
Cloudflare Registrar: domain availability, prices, registration via mcporter.
Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid…
Design and build AI agents for any domain. Use when users: (1) ask to "create an agent", "build an assistant", or "design an AI…