Incorporate mqtt into appcelerator / titanium - module

Does anybody have successful experience incorporating an mqtt library into Appcelerator / Titanium?
What library have you used
How do you incorporate that library (i.e. npm module, hyperloop, cocoapods,
straight source code, etc)
Thanks in advance for any help you can give

The only existing module I could find is http://gitt.io/component/it.uhopper.mqtt but last updated in 2014. So you'll have to find an (iOS?) library and then either wrap it as module or use Hyperloop but be aware that HL is still in beta.

Related

Expo integration with Google Sign In

I am trying to add login via Google account to my application. I have encountered a problem. Expo offers two solutions.
Google (https://docs.expo.dev/versions/latest/sdk/google/) - This can only be used in a development environment. I have used it but it does not work in a standalone application, in my case it throws the error "redirect_uri_mismatch" /
GoogleSignIn (https://docs.expo.dev/versions/latest/sdk/google-sign-in/) - Doesn't work in the emulator so I can't add it to the application because I can't fix potential errors.
My question is what the hell library should I use?
I have already tried expo eject and use Google Sign In from React Native. However I got an error that Expo does not support custom native modules. Help!
Thanks in advance.
Edit: SDK 44 Release
With the release of SDK 44, expo-google-sign-in has now been deprecated in favour of expo-auth-session OR #react-native-google-signin/google-signin packages. If you want to use the latter, you will need to follow the custom development client path.
Pre SDK 44
We've implemented Google-Sign-In using the expo-google-sign-in library. Implementation is easy enough, but you will have to test using a standalone build of your application which is the only slightly annoying piece of the puzzle.
Building a standalone build is now even easier with EAS (not sure if you have an account - but if you don't, I would highly recommend it.)
I've used a GoogleSignIn library, but I also have pro tip for everyone who will implement it.
Instead of building a project every time when you will need to test it, you can build it once and then just use upadate OTA, it's much faster.

Titanium Module (is there any module or support of App dynamics for titanium appcelrator)

We have Some question Related about app dynamics module in Appcelerator.
How to use the iOS libraries in the appcelerator module which supports the framework of appdynmics. Is it possible to add a iOS native library in appcelerator titanium ?
Is there any support for appdynmics in appcelerator Titanium ?
Is there any module for the appdynmics in appcelerator?
1.: Yes, you can extend Titanium by creating modules or using Hyperloop. The best option currently is to create a module. Some documentation is available at:
* https://devblog.axway.com/mobile-apps/write-titanium-ios-native-modules-swift/
* https://wiki.appcelerator.org/display/guides2/iOS+Module+Development+Guide
the 2nd link also has an Android section if you are interested in that too.
Appdynamics SDK documentation can be found here: https://docs.appdynamics.com/display/PRO45/Instrument+iOS+Applications
2. / 3. No (at least not on github). There is a page at http://gitt.io/search?q=appdynamics where you can search for modules on github
So you can either create one yourself or make a offer in the Ti-Slack Job section (ti-slack.slack.com/). Perhaps you'll find someone who will create one for you.

Is it necessary to link every react-native library after installation?

There are number of react-native libraries which makes developer job easy and it's a common practice to link library after it's installation. But for some libraries linking is not done(As those library developers are not asking to do so). For example react-native-swipeable for which linking was not asked on their git hub page. Another package native-base for which linking is mandatory but there was an error when i tired to do so, But still package is working fine.
Can somebody let me know the consequences that we face if any package is not linked?
Some libraries make use of native code, so linking should add to your project all native dependecies. For instance, react-native-swipeable might be a pure JS library and no linking is used. Which means no native code is used by react-native-swipeable.
For more information on linking please refer to: https://facebook.github.io/react-native/docs/linking#docsNav

how add Android project as library or add arr in android moudle project

I need to use a third-party SDK which must be added as aar or android project library.
I tried to unzip the aar and copy the /lib and /res files to my titanium android module project, but it didn't work.
the error looks like this:
The developer of the SDK tell me check out a link which is FATAL EXCEPTION: java.lang.NoClassDefFoundError: android.support.v7.appcompat.R$layout
I don't know how to solve it, hope someone could help me, thanks
Because Titanium is a Javascript cross platform tool to build native apps, you will need to write a wrapper to get a native functionality to work.
You can check out the documentation how to this on the Appcelerator website.
Unfortunately you can't just drop in a native component.

Add Bundle Version and Build to splash screen using PhoneGap

Using the latest PhoneGap what is the best guidance someone could give as to adding the Bundle Version and Build Number overlaying a PhoneGap Splash screen. I see this on other apps but most likely those apps may not have been built with PhoneGap. From what I have read you could use a UIView controller to do this to the didFinishLaunchingWithOptions method. I am not an Objective C coder and native apps are new to me so any guidance as to where to start would be helpful. I am on El Capitan using xCode 7.1.1. Is there a tutorial of sorts to getting this done? Is it a lengthy integration? Thanks for the help!
I haven't implemented this but have thought about it a couple times... one way of getting a cross platform solution might be to stamp the bundle / app version or whatever other information you want dynamically added to the splash using ImageMagick, and the Cordova hooks system to run a script each build to do this. We have done similar with a script that sets the version numbers in config.xml for Jenkins builds, so that we can associate Jenkins output with test builds. I would imagine the same mechanism could be used with the Annotating capability of Image Magick to have a platform independent way of achieving this.