You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/03/17 17:53:00 UTC

[jira] [Commented] (CB-13824) (Swift 4) Plugin class not found

    [ https://issues.apache.org/jira/browse/CB-13824?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16403655#comment-16403655 ] 

ASF GitHub Bot commented on CB-13824:
-------------------------------------

fssrepository commented on issue #353: CB-13824: (ios) Swift 4 support
URL: https://github.com/apache/cordova-ios/pull/353#issuecomment-373939586
 
 
   I have transformed a plugin from object c to swift, but i had a very hard time to make it work, it's working in xcode with emulator, but like use_frameworks! in the Pod file is missing, and there are some other issues, like cordova header file in a wrong place. GoogleToolboxForMac not found. The official cordova release with swift 4 is not working. (not picking up the methods of the plugin,with Swift 3 is definitely working)
   
   It's a very easy plugin, with just some lines of code to test the capacity of cordova on ios.
   Can somebody help me out on this? There are tons of bugs under cordova related to swift 4, which this plugin showed. I had to use an external plugin also to generate Bridign header, and AppDelegate.h was also required.
   
   https://github.com/fssrepository/cordova-plugin-fcm-modified

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


>  (Swift 4) Plugin class not found
> ---------------------------------
>
>                 Key: CB-13824
>                 URL: https://issues.apache.org/jira/browse/CB-13824
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: cordova-ios, cordova-osx
>            Reporter: Alberto Lalama
>            Assignee: Tobias Bocanegra
>            Priority: Minor
>             Fix For: 4.1.0
>
>
> After upgrading to Xcode 9.2 (Swift 4), some plugins were not found. Plugin method execution fails with the following message: "CDVPlugin class X (pluginName: Y) does not exist".
> Closer inspection reveals that NSClassFromString returns nil for plugins implemented in Swift. Prefixing the class with the module name fixes the issue.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org