Skip to content

Add iOS development docs#3052

Open
bgoncal wants to merge 17 commits intohome-assistant:masterfrom
bgoncal:ios-docs
Open

Add iOS development docs#3052
bgoncal wants to merge 17 commits intohome-assistant:masterfrom
bgoncal:ios-docs

Conversation

@bgoncal
Copy link
Copy Markdown
Member

@bgoncal bgoncal commented Apr 15, 2026

Proposed change

Add a dedicated iOS developer documentation section, modeled after the existing Android developer docs and based on the current Home Assistant iOS repository structure and contributor workflow.

This PR adds an iOS landing page plus contributor-focused pages for getting started, architecture, targets, testing, code style, CI, and submitting changes. It also updates site navigation so the new iOS section appears in the homepage, navbar, and left sidebar like the Android docs.

Type of change

  • Document existing features within Home Assistant
  • Document new or changing features for which there is an existing pull request elsewhere
  • Spelling or grammatical corrections, or rewording for improved clarity
  • Changes to the backend of this documentation
  • Remove stale or deprecated documentation

Checklist

  • I have read and followed the documentation guidelines.
  • I have verified that my changes render correctly in the documentation.

Additional information

Summary by CodeRabbit

  • Documentation
    • Added comprehensive Apple platforms documentation section with guides for getting started, architecture overview, build targets, testing, continuous integration, code style requirements, and contribution submissions.
    • Updated site navigation to include Apple platforms link.
    • Added Apple platforms reference to homepage featuring the iOS companion app.

@bgoncal bgoncal self-assigned this Apr 15, 2026
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 15, 2026

Warning

Rate limit exceeded

@bgoncal has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 48 minutes and 18 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 48 minutes and 18 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 82f90768-bcd5-442b-83d2-fd4147551e53

📥 Commits

Reviewing files that changed from the base of the PR and between a49bd3c and 342a41a.

📒 Files selected for processing (1)
  • docs/apple/architecture.md
📝 Walkthrough

Walkthrough

This change adds comprehensive Apple platforms documentation to the Home Assistant project website. Navigation configuration is updated to include "Apple platforms" in the navbar menu, sidebar structure adds a new "Apple" section with eight documentation pages, and the homepage is updated with Apple platforms references. Eight new documentation files provide getting started guides, architecture overview, build targets information, testing procedures, CI/CD setup details, code style guidelines, and contribution submission instructions.

Changes

Cohort / File(s) Summary
Navigation & Site Configuration
docusaurus.config.js, sidebars.js, src/pages/index.js
Added navbar menu entry for "Apple platforms" linking to /docs/apple. Created new top-level Apple sidebar section with eight documentation entries. Updated homepage with "Apple platforms" contribution paragraph and iOS repository link in Popular Topics.
Apple Platforms Documentation
docs/apple/index.md, docs/apple/get_started.md, docs/apple/architecture.md, docs/apple/targets.md, docs/apple/testing.md, docs/apple/ci.md, docs/apple/codestyle.md, docs/apple/submit.md
Added eight new documentation files covering introduction, onboarding with setup instructions, codebase architecture overview, build targets enumeration, testing procedures, GitHub Actions/Fastlane CI setup, code style enforcement tools and conventions, and contribution submission guidelines.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~15 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Add iOS development docs' is concise and directly reflects the main objective of adding comprehensive iOS developer documentation with 8 new docs pages plus navigation updates.
Description check ✅ Passed The description is well-structured, follows the template, and provides clear details: proposed change explains the iOS docs addition, type of change is properly marked, checklist items are completed with verification claims, and relevant upstream sources are linked.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (1)
docs/ios/ci.md (1)

44-50: Avoid hardcoding CI runtime versions in docs.

Pinpoint values like Xcode 26.2 / iPhone 17 / iOS 26.2 will go stale quickly and cause doc drift. Prefer wording like “current CI Xcode/simulator versions” and link to the workflow file as source of truth.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/ios/ci.md` around lines 44 - 50, Replace hardcoded runtime/version
mentions ("Xcode 26.2", "iPhone 17", "iOS 26.2") in the docs snippet and instead
describe them as the "current CI Xcode/simulator versions" and refer readers to
the CI workflow as the source of truth; update the Fastlane description that
references the `Tests-Unit` scheme and `HomeAssistant.xcworkspace` to say it
runs the unit tests on the CI-configured simulator (rather than naming a
specific device/os), and add a link or pointer to the workflow file where the
exact Xcode and simulator versions are defined.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/ios/get_started.md`:
- Around line 85-90: Reword the run steps to use location-first phrasing and
bold UI strings: change each step to start with the target (e.g., "In Xcode,
open **HomeAssistant.xcworkspace**"), "In the scheme selector, choose
**App-Debug**", "In the device selector, choose an iOS simulator or a
development device", and "In Xcode, build and run." Also make **App-Debug** and
other UI labels bold to match repository style.
- Line 100: Replace the fragment heading "Autocorrect supported issues:" with a
goal-fronted, action-oriented label such as "Run autocorrect on supported
issues" (or "Apply autocorrect to supported issues") in the
docs/ios/get_started.md heading; update the visible heading text where the
string "Autocorrect supported issues:" appears to use that imperative phrasing
to comply with the Microsoft Style Guide.

In `@docs/ios/submit.md`:
- Line 2: The page title "iOS submit contribution" is awkward; update the title
value in the frontmatter (currently title: "iOS submit contribution") to a more
natural phrase such as "Submit an iOS contribution" or "iOS contribution
submission" so navigation and headers read clearly.

In `@docs/ios/testing/introduction.md`:
- Around line 61-64: Reword the Xcode instruction to front the location phrase
and format UI-facing strings in bold: change the sentence to start with the
location ("In Xcode, open **HomeAssistant.xcworkspace**") and render the test
scheme names as bold UI strings (e.g., **Tests-Unit**, **Tests-UI**) instead of
inline code; update the sentence containing "run the relevant test scheme
directly" so the location phrase leads and the scheme names use bold formatting.

---

Nitpick comments:
In `@docs/ios/ci.md`:
- Around line 44-50: Replace hardcoded runtime/version mentions ("Xcode 26.2",
"iPhone 17", "iOS 26.2") in the docs snippet and instead describe them as the
"current CI Xcode/simulator versions" and refer readers to the CI workflow as
the source of truth; update the Fastlane description that references the
`Tests-Unit` scheme and `HomeAssistant.xcworkspace` to say it runs the unit
tests on the CI-configured simulator (rather than naming a specific device/os),
and add a link or pointer to the workflow file where the exact Xcode and
simulator versions are defined.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 84df2848-fe4b-4d5c-b502-400d1dc0012c

📥 Commits

Reviewing files that changed from the base of the PR and between a07ecbc and df05848.

📒 Files selected for processing (11)
  • docs/ios.md
  • docs/ios/architecture.md
  • docs/ios/ci.md
  • docs/ios/codestyle.md
  • docs/ios/get_started.md
  • docs/ios/submit.md
  • docs/ios/targets.md
  • docs/ios/testing/introduction.md
  • docusaurus.config.js
  • sidebars.js
  • src/pages/index.js

Comment thread docs/ios/get_started.md Outdated
Comment thread docs/ios/get_started.md Outdated
Comment thread docs/ios/submit.md Outdated
Comment thread docs/ios/testing/introduction.md Outdated
@bgoncal bgoncal requested review from c0ffeeca7 and joostlek April 15, 2026 01:55
Comment thread docusaurus.config.js Outdated
Comment thread docs/apple/index.md
Comment thread docs/ios.md Outdated
Comment thread docs/ios/codestyle.md Outdated
Comment thread docs/apple/testing.md
Comment thread docs/apple/get_started.md
Comment thread docs/ios/get_started.md Outdated
Comment thread docs/ios/submit.md Outdated
Comment thread docs/ios/submit.md Outdated
Comment thread docs/apple/targets.md
Co-authored-by: Joost Lekkerkerker <joostlek@outlook.com>
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
docs/ios/get_started.md (2)

112-114: Add a direct link to the README section for frontend testing.

The text now clarifies that "frontend" refers to the embedded WebView, but redirecting readers to "the repository README" without a specific link or inline summary makes it harder to find the workflow. Consider adding a direct link to the relevant README section or providing a brief inline summary of the steps.

📝 Suggested improvement

If a specific README anchor exists:

-If you only want to validate frontend changes, you can install the simulator app artifact produced by CI and debug the embedded WebView with Safari Web Inspector. The repository README documents that workflow in more detail.
+If you only want to validate frontend changes, you can install the simulator app artifact produced by CI and debug the embedded WebView with Safari Web Inspector. The [repository README](https://github.com/home-assistant/iOS#frontend-development) documents that workflow in more detail.

Alternatively, provide a brief inline summary:

-If you only want to validate frontend changes, you can install the simulator app artifact produced by CI and debug the embedded WebView with Safari Web Inspector. The repository README documents that workflow in more detail.
+If you only want to validate frontend changes, you can install the simulator app artifact produced by CI and debug the embedded WebView with Safari Web Inspector:
+
+1. Download the simulator app artifact from a CI run.
+2. Install it on an iOS simulator.
+3. Open Safari Web Inspector to debug the WebView.
+
+The [repository README](https://github.com/home-assistant/iOS) provides additional details.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/ios/get_started.md` around lines 112 - 114, The "Testing just the
frontend" section should include a direct pointer to the exact README section or
a short inline summary of the workflow; update the heading content to either add
a link to the specific README anchor for frontend/WebView testing (the README
section that describes installing the simulator artifact and using Safari Web
Inspector) or insert a one- or two-sentence inline summary of the steps (e.g.,
download/install the CI-produced simulator app artifact, launch the simulator,
enable the embedded WebView remote debugging and open Safari Web Inspector) so
readers can immediately follow the workflow without hunting for the referenced
README.

16-16: Consider adding installation links for Ruby version managers.

While the dependency installation section below provides concrete examples, adding direct links to Homebrew, rbenv, or mise installation pages here would help new contributors quickly set up their environment.

📚 Suggested enhancement
-- Ruby 3.1 with either Homebrew, `rbenv`, or `mise`
+- Ruby 3.1 with either [Homebrew](https://brew.sh/), [rbenv](https://github.com/rbenv/rbenv), or [mise](https://mise.jdx.dev/)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/ios/get_started.md` at line 16, Update the "Ruby 3.1 with either
Homebrew, `rbenv`, or `mise`" line in docs/ios/get_started.md to include direct
installation links for Homebrew, rbenv, and mise (e.g., link text to their
official install pages) so new contributors can click through; ensure the
sentence still mentions Ruby 3.1 and retains the inline code formatting for
`rbenv` and `mise`.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@docs/ios/get_started.md`:
- Around line 112-114: The "Testing just the frontend" section should include a
direct pointer to the exact README section or a short inline summary of the
workflow; update the heading content to either add a link to the specific README
anchor for frontend/WebView testing (the README section that describes
installing the simulator artifact and using Safari Web Inspector) or insert a
one- or two-sentence inline summary of the steps (e.g., download/install the
CI-produced simulator app artifact, launch the simulator, enable the embedded
WebView remote debugging and open Safari Web Inspector) so readers can
immediately follow the workflow without hunting for the referenced README.
- Line 16: Update the "Ruby 3.1 with either Homebrew, `rbenv`, or `mise`" line
in docs/ios/get_started.md to include direct installation links for Homebrew,
rbenv, and mise (e.g., link text to their official install pages) so new
contributors can click through; ensure the sentence still mentions Ruby 3.1 and
retains the inline code formatting for `rbenv` and `mise`.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 13e6576c-58f3-4909-b985-4807da511b33

📥 Commits

Reviewing files that changed from the base of the PR and between df05848 and b2a3b45.

📒 Files selected for processing (4)
  • docs/ios/ci.md
  • docs/ios/get_started.md
  • docs/ios/submit.md
  • docs/ios/testing/introduction.md
✅ Files skipped from review due to trivial changes (3)
  • docs/ios/testing/introduction.md
  • docs/ios/ci.md
  • docs/ios/submit.md

Comment thread docs/ios/codestyle.md Outdated
Comment thread docs/ios/codestyle.md Outdated
Comment thread docs/ios/get_started.md Outdated
Comment thread docs/ios/testing/introduction.md Outdated
Comment thread docs/ios/testing/introduction.md Outdated
Comment thread docs/ios/architecture.md Outdated
Comment thread docs/ios/architecture.md Outdated
bgoncal and others added 7 commits April 20, 2026 14:01
Co-authored-by: Martin Claesson <43297668+Claeysson@users.noreply.github.com>
Co-authored-by: Martin Claesson <43297668+Claeysson@users.noreply.github.com>
…nt into ios-docs

# Conflicts:
#	docs/ios/ci.md
#	docs/ios/get_started.md
#	docs/ios/testing/introduction.md
Comment thread docs/apple/architecture.md Outdated
@bgoncal bgoncal requested review from Claeysson and joostlek April 20, 2026 14:14
Comment on lines 104 to 115
```mermaid
flowchart LR
App["Sources/App<br/>(iPhone and iPad app)"] --> Shared["Sources/Shared<br/>(cross-target logic)"]
Shared --> Extensions["Sources/Extensions<br/>(widgets, App Intents, notifications, …)"]
Shared --> CarPlay["Sources/CarPlay"]
Shared --> Watch["Sources/Watch and Sources/WatchApp"]
graph TD;
App[Sources/App - iPhone and iPad app]
Shared[Sources/Shared - cross-target logic]
Extensions[Sources/Extensions - widgets, App Intents, notifications]
CarPlay[Sources/CarPlay]
Watch[Sources/Watch and Sources/WatchApp]
App --> Shared
Shared --> Extensions
Shared --> CarPlay
Shared --> Watch
```
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I start to like the graph, I think it adds a lot. Mind if I throw you something?

Image

I think currently it kinda shows the flow chart from the steps down below, but would it make more sense to have it explain the structure for the user? So

  1. If I have the WatchOS app, what components are involved? From what I understand now it'd be App, Shared, Watch (and maybe Extensions)
  2. If I maybe want to make a change to the shared part, Can I see in one view where this is used?
  3. I think it'd be cool if we can remove Source/ (or maybe play with adding a <br /> so the location is on a single line as now it breaks off.
  4. You can add links to these models, so you could link it to the iOS repository
Image

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I tried to ask claude but it failed, looks very wrong, I will play with it a bit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants