Closed abegehr closed 1 month ago
closing as duplicate of https://github.com/ionic-team/capacitor-docs/issues/275
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.
Capacitor Version
π Capacitor Doctor π
Latest Dependencies:
@capacitor/cli: 6.0.0 @capacitor/core: 6.0.0 @capacitor/android: 6.0.0 @capacitor/ios: 6.0.0
Installed Dependencies:
@capacitor/android: not installed @capacitor/cli: 6.0.0 @capacitor/core: 6.0.0 @capacitor/ios: 6.0.0
[success] iOS looking great! π
Other API Details
Platforms Affected
Current Behavior
I've followed the docs for adding custom native code to iOS: https://capacitorjs.com/docs/ios/custom-code - however the EchoPlugin is never called.
Expected Behavior
I would expect the EchoPlugin to load and be called. This doesn't occur even though I've followed the docs exactly.
Project Reproduction
https://github.com/abegehr/capacitor-sample/commit/08fc81759bdaebb4e516b4f6fe03eee4e0e9dc9c
Additional Information
After some digging, I found that plugins are registered in iOS based on the
packageClassList
parameter on the config json: https://github.com/ionic-team/capacitor/blob/5b2ab7c68db4e77b8b2961e927acc5a708ee260f/ios/Capacitor/Capacitor/CapacitorBridge.swift#L9 - however the generated config json has an empty list underpackageClassList
. I tried adding the plugin name underplugins
on the src config file but no change. Manually adding "EchoPlugin" topackageClassList
in the generated config json file works however the file is overwritten on the next sync.