Skip to content

Conversation

@Kyle-Ye
Copy link
Collaborator

@Kyle-Ye Kyle-Ye commented Oct 6, 2025

Summary

This PR adds a comprehensive integration guide (INTEGRATION.md) for developers who want to use OpenSwiftUI in their projects.

What's Included

Documentation

  • INTEGRATION.md: Complete step-by-step integration guide
    • Separate instructions for Swift Package Manager (SPM) and Xcode projects
    • Package dependency setup (branch/revision instead of tags due to unsafeFlags)
    • DarwinPrivateFrameworks xcframework configuration
    • Platform-specific notes and troubleshooting

Screenshots

  • Added visual guides in Screenshots/Integration/:
    • add-package-dependency.png: Adding OpenSwiftUI package
    • show-in-finder.png: Locating DarwinPrivateFrameworks
    • add-xcframeworks.png: Configuring xcframeworks with "Do Not Embed"

Key Features

  • ✅ Prerequisites and version requirements (Xcode 16.4, Swift 6.1.2+, macOS 15.5/iOS 18.5)
  • ✅ Branch/revision dependency instructions (cannot use tags due to unsafeFlags)
  • ✅ Manual xcframework setup for Darwin platforms
  • ✅ Known Limitations section:
    • iOS device builds not supported (until OpenAttributeGraph is ready)
    • ABI compatibility requirements (iOS 18.5/macOS 15.5 until ViewUpdater is ready)
  • ✅ Platform support and troubleshooting guide

README Updates

  • Added prominent link to INTEGRATION.md in Usage section
  • Organized Usage section with Integration Guide and Example Application

Testing

  • Documentation tested with sample Xcode project integration
  • All screenshots verified for accuracy

Close #519

This guide provides step-by-step instructions for integrating OpenSwiftUI
into Xcode projects, including:
- Using branch/revision dependencies instead of tags (due to unsafeFlags)
- Manually adding DarwinPrivateFrameworks xcframeworks
- Platform-specific setup and troubleshooting tips
@github-actions github-actions bot added documentation Improvements or additions to documentation platform: iOS platform: macOS labels Oct 6, 2025
Kyle-Ye added 10 commits October 6, 2025 20:35
Add renamed screenshots for the integration guide:
- add-package-dependency.png: Shows adding OpenSwiftUI package
- show-in-finder.png: Shows locating DarwinPrivateFrameworks
- add-xcframeworks.png: Shows adding xcframeworks with "Do Not Embed"
- Clarify Darwin platforms (not just macOS) need xcframework setup
- Update platform support info: macOS, iOS simulator supported; visionOS experimental
- Note iOS device builds not supported due to missing AttributeGraph symbols
- Update error message to more specific CFBundleExecutable error
- Remove redundant sections for better clarity
Integration guide updates:
- Add ABI compatibility requirements section
- Note that current Render engine uses SwiftUI private API without ABI guarantee
- Document supported ABI versions: iOS 18.5 and macOS 15.5
- Clarify iOS device build limitations

README updates:
- Add reference to INTEGRATION.md in Usage section
- Organize Usage section with Integration Guide and Example Application
- Consolidate iOS device build limitation and ABI compatibility requirements
- Add numbered list for clarity
- Include affected platforms and workarounds for each limitation
- Improve documentation structure and readability
- Limitation 1: Will be lifted when OpenAttributeGraph is ready (unlocks iOS device support)
- Limitation 2: Will be lifted when OpenSwiftUI's Render engine is ready (removes ABI version lock)
- Clarify the path forward for resolving each limitation
Prerequisites changes:
- Update Xcode version to 16.4
- Update platform requirements to macOS 15.5 / iOS 18.5 to match ABI requirements

Screenshots organization:
- Move screenshots to Screenshots/Integration/ directory
- Update all image references in INTEGRATION.md
- Use GitHub-style warning callout block for better visibility
- Split message into multiple lines for better readability
- Separate integration steps for Swift Package vs Xcode project
- Step 1 (SwiftPM): Add package dependency with branch/revision
- Step 1-3 (Xcode): Add package, handle xcframeworks, add required frameworks
- Improve "Why This Is Needed" section with NOTE callout
- Update code example to show VStack with Color views
- Add note about limited API/View support
- Update intro to cover both SwiftPM and Xcode projects
- Fix section naming: "Swift Package Manager (SPM)" and "Xcode Project"
- Resolve step numbering: "Using OpenSwiftUI in Your Code" (shared section)
- Fix grammar: "APIs and Views are" (plural)
- Improve NOTE callout formatting for consistency
@Kyle-Ye Kyle-Ye force-pushed the docs/integration-guide branch from dfcdbd8 to 3ea5b40 Compare October 6, 2025 12:36
@codecov
Copy link

codecov bot commented Oct 6, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 24.62%. Comparing base (97347da) to head (cc57f53).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #553      +/-   ##
==========================================
- Coverage   24.64%   24.62%   -0.02%     
==========================================
  Files         505      505              
  Lines       29204    29204              
==========================================
- Hits         7197     7192       -5     
- Misses      22007    22012       +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

- Document full debug support with screenshot
- Note that Xcode Preview support is under development
- Add openswiftui-debug.png showing debugging capabilities
@github-actions github-actions bot added the enhancement New feature or request label Oct 6, 2025
@Kyle-Ye Kyle-Ye merged commit 54b03b1 into main Oct 6, 2025
7 of 8 checks passed
@Kyle-Ye Kyle-Ye deleted the docs/integration-guide branch October 6, 2025 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request platform: iOS platform: macOS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Module completely fails to import into Xcode

2 participants