fix(ios): enregistre le plugin CoachAppleAuth dans capacitorDidLoad

Capacitor 8 n'auto-découvre pas les plugins in-app : il faut les registrer
explicitement via bridge.registerPluginInstance(). CoachAppleAuthPlugin avait
été créé mais pas ajouté à la liste → window.Capacitor.Plugins.CoachAppleAuth
restait undefined → bouton Apple natif absent. Corrigé.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Sylvain Bettinelli
2026-06-04 19:38:55 +00:00
parent c407aa8364
commit eee199a5ed

View File

@@ -22,6 +22,9 @@ class MainViewController: CAPBridgeViewController {
// watchOS CoachWatch via WatchConnectivity, relaie au JS (event // watchOS CoachWatch via WatchConnectivity, relaie au JS (event
// "liveSample") pour la page /live (cf. CoachLiveBridge.swift). // "liveSample") pour la page /live (cf. CoachLiveBridge.swift).
bridge?.registerPluginInstance(CoachLiveBridgePlugin()) bridge?.registerPluginInstance(CoachLiveBridgePlugin())
// Plugin natif Sign in with Apple signIn() natif (AuthenticationServices)
// identity_token POSTé sur /auth/apple/web (cf. CoachAppleAuth.swift).
bridge?.registerPluginInstance(CoachAppleAuthPlugin())
} }
override func viewDidLoad() { override func viewDidLoad() {