Skip to content

refactor: introduce Dependencies container and remove singletons#142

Merged
philprime merged 1 commit into
mainfrom
feature/di
Jun 24, 2026
Merged

refactor: introduce Dependencies container and remove singletons#142
philprime merged 1 commit into
mainfrom
feature/di

Conversation

@philprime

Copy link
Copy Markdown
Member

Summary

  • Introduce a Dependencies struct as a centralized dependency container, replacing singleton access patterns (AppHealthObserver.shared, MetricKitManager.shared)
  • Make ModelContainer creation lazy and throwing via LazyThrowingValue, so Sentry is configured before first access and can capture initialization failures
  • Add @MainActor to Dependencies to enforce main-thread access

Test plan

  • Verify app launches correctly on device/simulator
  • Verify toasts still appear on feedback submit success/error
  • Verify Sentry events are still reported
  • Verify MetricKit and app health observation still function

@philprime philprime force-pushed the feature/feedback-button branch from 6e9678f to 15a0130 Compare June 24, 2026 07:08
Base automatically changed from feature/feedback-button to main June 24, 2026 07:47
Comment thread Targets/App/Sources/UI/LinkDetail/LinkDetailRenderView.swift
@sentry

sentry Bot commented Jun 24, 2026

Copy link
Copy Markdown

📲 Install Builds

iOS

🔗 App Name App ID Version Configuration
Flinky com.techprimate.Flinky 1.1.5 (3) --

⚙️ flinky Build Distribution Settings

@philprime philprime enabled auto-merge (squash) June 24, 2026 08:16
@philprime philprime merged commit 59b3cec into main Jun 24, 2026
7 checks passed
@philprime philprime deleted the feature/di branch June 24, 2026 08:20
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.

1 participant