walterholohan / react-native-crisp-chat-sdk

React-Native bridge for Crisp Chat iOS and Android SDK's
MIT License
70 stars 26 forks source link

Expo bare minimum template issue with swift compile #1

Closed Carlosreyesk closed 3 years ago

Carlosreyesk commented 4 years ago

Hello, im not sure if im missing something but ive tried to install the npm package following the readme. Im using an expo bare minimum template which should work just like react-native. Im getting the following error when running the react-native ios after following all steps.

BUILD FAILED

The following build commands failed: CompileSwift normal x86_64 /Users/carlosreyes/Zarmada/mobile-app-poc/MobileApp/node_modules/react-native-crisp-chat-sdk/ios/CrispChatSdk.swift CompileSwift normal x86_64 /Users/carlosreyes/Zarmada/mobile-app-poc/MobileApp/node_modules/react-native-crisp-chat-sdk/ios/CrispChatView.swift CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler (3 failures)

error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

wahaj-47 commented 4 years ago

I'm getting the same error.

walterholohan commented 4 years ago

Have you created a bridging header in your iOS folder in order for the swift files to be compiled? Instructions can be found in the README - https://github.com/walterholohan/react-native-crisp-chat-sdk#additional-steps

Also what version of react-native are you using?

wahaj-47 commented 4 years ago

Yes I've created the bridging header, the pod won't install without it. I'm using react-native version: 0.61.5

walterholohan commented 4 years ago

@wahaj-47 @Carlosreyesk I have just pushed a new version (v0.1.3) that should fix above, however, Crisp has released a new version of their iOS SDK (v1.0.3). A refactor of this RN bridge will be needed in order to use their new version. I hope to get some time in the coming weeks to do this.

walterholohan commented 4 years ago

Apologies I forgot to publish the changes to NPM. 0.1.3 should be ready to download now. Let me know if it solves the issue on your end.

wahaj-47 commented 4 years ago

I downloaded it directly from github and yes it did solved the issue.

walterholohan commented 4 years ago

Lovely stuff. How's your native iOS skills? I had a go yesterday at upgrading the iOS bridge to use https://github.com/crisp-im/crisp-sdk-ios/releases/tag/1.0.3 but didn't get far. Currently, it's just rendering a UI view but now the new version of Crisp-sdk-ios use a UIViewController instead which I am struggling to get working.

wahaj-47 commented 4 years ago

My native skills are zero. I've only recently dived into native code.