timmyy123/llm-hub/uikit-ui-common-setup
Claude Code and agent skill by timmyy123/llm-hub
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Use when writing or refactoring UIKit UI in this repo, especially Workflow/ViewController wiring, Controller/View components, SnapKit layout, Workspace/Dflat-driven UI state, Objective-C adapter responders, or app threading boundaries.
Install
npx vskill@latest install timmyy123/llm-hub/uikit-ui-common-setupSKILL.md
UIKit UI Common Setup
First Pass
- Read nearby app code before introducing a new shape.
- Prefer existing Draw Things / Local Code UIKit patterns over new abstractions.
- Use
rg/rg --filesto find matchingWorkflow,ViewController, andControllerexamples.
Workflow And ViewController
- UI screens are managed by
Workflowobjects. - A
Workflowowns the concreteUIViewController. - Expose
viewControllerwhen the workflow needs the concrete type, andviewControllableas the generic UIKit-facingUIViewController. UIViewControllersubclasses are views plus UIKit event handling only.- Do not put business logic, persistence policy, generation logic, networking, model work, or off-main-thread work in a
UIViewController. UIViewControllersends events out through delegates. TheWorkflowhandles them and sets properties back on the view controller.
Controller And View
- For shared business logic outside a workflow, use Controller & View.
- A controller is a plain Swift class, not
NSObjectand not a UIKit subclass. - It owns one root
UIViewproperty, usuallylet view: UIView. - Controllers are usually owned by workflows. Letting a view controller own one is only for lightweight, mostly animation-focused cases.
Layout And View Setup
- Use lazy vars for referenced views. Each lazy var configures that view and self-contained subviews.
- Put hierarchy assembly and cross-view SnapKit constraints inline in
viewDidLoador the controller initializer. - In
viewDidLoador the controller initializer, do layout first, then action/delegate hookups. - Do not create one-off
configureXXX/setupXXXmethods for view setup, layout, or action wiring. - Domain helpers are fine when they express behavior or reusable construction, such as
makeProjectMenu,updateSettingsSections, ordidTapCollapseOrExpand.
One-Way Dataflow
- Persisted UI state should flow from Dflat /
Workspace/workspace.dictionaryobservations into UI properties. - Delegate callbacks should write source-of-truth state or call workflow/controller behavior, not directly mutate unrelated UI state.
- Even
didSet-driven UI updates should be reached through the owningWorkflowor real Controller when the state is not purely local view presentation. - Keep view controllers as render targets: set properties on them; let them update UIKit controls.
Objective-C And UIKit Adapters
- A
UIViewControlleralready inherits fromNSObject; using it for UIKit lifecycle/delegates is fine. - Plain controllers must stay plain Swift classes.
- When a plain controller needs Objective-C delegation, target/action, or UIKit delegate conformance, create a nested responder such as
Controller.ObjCResponder: NSObject. - The responder forwards callbacks back to the controller; it does not own business logic.
Threads And Queues
- Do not use
async/awaitin app UI code. UIViewControllersubclasses and views should only touch main-thread UIKit state.- Workflow and Controller objects are the right places for off-main-thread behavior.
- Avoid creating private queues per workflow/controller. Reuse existing shared queues when behavior fits.
- Prefer one or two shared queues for broad work classes, like Draw Things' edit queue handling generation, tokenization, and related work.
- Create a new queue only when the behavior truly needs a separate serialization or QoS boundary. For rare fire-and-forget work, a global concurrent queue can be acceptable.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingios/LLMHub/LocalPackages/draw-things-community/.agents/skills/uikit-ui-common-setup/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/timmyy123/llm-hub/uikit-ui-common-setup)