ios-uikit-advanced/SKILL.md
Advanced UIKit for production iOS apps — UICollectionViewDiffableDataSource with NSDiffableDataSourceSnapshot, UICollectionViewCompositionalLayout (sections with orthogonal scrolling, badges, headers), UIViewControllerTransitioningDelegate for...
npx skillsauth add peterbamuhigire/skills-web-dev ios-uikit-advancedInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
ios-uikit-advanced or would be better handled by a more specific companion skill.references only as needed.SKILL.md first, then load only the referenced deep-dive files that are necessary for the task.references/ directory for deep detail after reading the core workflow below.Production-grade UIKit patterns for polished, crash-free iOS interfaces. No placeholder patterns — every section is ready to ship.
The old beginUpdates/endUpdates pattern crashes when data changes occur during animation. Diffable data source computes diffs automatically and applies them safely.
enum Section { case main, featured }
struct Item: Hashable {
let id: UUID
let title: String
// Hashable identity is all diffable needs — diff is computed automatically
}
class ContactsViewController: UIViewController {
private var dataSource: UITableViewDiffableDataSource<Section, Item>!
override func viewDidLoad() {
super.viewDidLoad()
configureDataSource()
}
private func configureDataSource() {
dataSource = UITableViewDiffableDataSource<Section, Item>(
tableView: tableView
) { tableView, indexPath, item in
let cell = tableView.dequeueReusableCell(withIdentifier: "Cell", for: indexPath)
var config = cell.defaultContentConfiguration()
config.text = item.title
cell.contentConfiguration = config
return cell
}
}
func applySnapshot(items: [Item], animatingDifferences: Bool = true) {
var snapshot = NSDiffableDataSourceSnapshot<Section, Item>()
snapshot.appendSections([.main])
snapshot.appendItems(items, toSection: .main)
dataSource.apply(snapshot, animatingDifferences: animatingDifferences)
}
// Reload specific items without full reload (iOS 15+)
func updateItem(_ item: Item) {
var snapshot = dataSource.snapshot()
snapshot.reconfigureItems([item]) // preserves cell height animation
dataSource.apply(snapshot, animatingDifferences: true)
}
}
Multi-section snapshots:
var snapshot = NSDiffableDataSourceSnapshot<Section, Item>()
snapshot.appendSections([.featured, .main])
snapshot.appendItems(featuredItems, toSection: .featured)
snapshot.appendItems(regularItems, toSection: .main)
// Move items between sections:
snapshot.moveItem(item, afterItem: otherItem)
snapshot.moveSection(.featured, afterSection: .main)
dataSource.apply(snapshot)
Extended guidance for ios-uikit-advanced was moved to references/skill-deep-dive.md to keep this entrypoint compact and fast to load.
Use that deep dive for:
SECTION 2: Compositional Layout — Complex Collection LayoutsSECTION 3: Custom View Controller TransitionsSECTION 4: UIViewPropertyAnimator — Interruptible AnimationsSECTION 5: Context MenusSECTION 6: Bottom Sheets with UISheetPresentationControllerSECTION 7: NSFetchedResultsController with Diffable Data SourceSECTION 8: Prefetching for Smooth ScrollingSECTION 9: Production Anti-PatternsSECTION 10: Advanced Interactions ReferenceQuick-Reference Checklistdata-ai
Use when adding AI-powered analytics to a SaaS platform — semantic search over business data, natural language queries, trend detection, anomaly alerts, and AI-generated insights for dashboards. Covers embeddings, NL2SQL, and per-tenant analytics...
data-ai
Design AI-powered analytics dashboards — what metrics to show, how to display AI predictions and confidence, drill-down patterns, KPI cards, trend visualisation, AI Insights panels, export design, and role-based dashboard variants. Invoke when...
development
Use when designing, building, reviewing, or upgrading production software systems that must be secure, performant, maintainable, scalable, and user-centered. Apply before writing specs, code, architecture, APIs, databases, mobile apps, SaaS platforms, or ERP systems.
development
Professional web app UI using commercial templates (Tabler/Bootstrap 5) with strong frontend design direction when needed. Use for CRUD interfaces, dashboards, admin panels with SweetAlert2, DataTables, Flatpickr. Clone seeder-page.php, use...