swiftui-webkit

Embed and control web content in SwiftUI apps with WebView and WebPage APIs.

4|1|Updated Apr 2, 2026
One-click install
npx skills add https://github.com/AutisticAF/claude-code-apple-dev-plugin --skill swiftui-webkit-autisticaf
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: swiftui-webkit
Source: https://github.com/AutisticAF/claude-code-apple-dev-plugin/tree/main/skills/swiftui-webkit
Command: npx skills add https://github.com/AutisticAF/claude-code-apple-dev-plugin --skill swiftui-webkit-autisticaf

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

SwiftUI developers need to display and interact with web content inside their apps without switching contexts or relying on UIKit wrappers.

Core Features & Use Cases

  • Embedding WebView in SwiftUI using WebPage for full control (loading, navigation, JavaScript)
  • JavaScript interop with content isolation and frame targeting
  • Snapshot, PDF export, and page navigation intercept
  • Custom URL scheme handling and navigation decisions

Quick Start

Load a URL into a SwiftUI WebView and begin controlling navigation and JavaScript execution via WebPage.

Frequently Asked Questions about swiftui-webkit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I embed and control web content in SwiftUI without using UIKit wrappers?

SwiftUI web embedding is achieved via the WebPage API, which provides full control over loading URLs, executing JavaScript, and intercepting navigation without relying on UIKit wrappers.

Can I run JavaScript with content isolation inside a SwiftUI WebView?

Yes, JavaScript interop in SwiftUI WebView supports optional content worlds for content isolation, allowing targeted script execution within specific frame contexts.

What is the best way to intercept navigation decisions in a SwiftUI WebView?

Intercept navigation in SwiftUI WebView by implementing the NavigationDeciding protocol to evaluate requests, handle custom URL schemes, and control page routing decisions.

Does SwiftUI WebKit support capturing snapshots and exporting PDFs from web pages?

Yes, SwiftUI WebKit supports capturing snapshots and exporting web page content to PDF, alongside features for custom URL scheme handling and JavaScript execution.

How do I handle custom URL schemes when loading web content in SwiftUI?

Handle custom URL schemes in SwiftUI by configuring navigation decisions through the NavigationDeciding protocol, intercepting and routing custom scheme requests within the web view.

Why use the WebPage API instead of standard WebView for displaying web content in SwiftUI?

The WebPage API provides full control over SwiftUI web content, including advanced navigation decisions, JavaScript interop with content worlds, and snapshot capture, whereas standard WebView provides basic display.