Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-24948] Hyperloop: iOS - Cannot build iOS 11 API's

GitHub Issuen/a
TypeNew Feature
PriorityHigh
StatusClosed
ResolutionInvalid
Resolution Date2017-09-15T14:46:24.000+0000
Affected Version/sHyperloop 2.1.2
Fix Version/sn/a
ComponentsHyperloop, iOS
Labelsn/a
ReporterHans Knöchel
AssigneeJan Vennemann
Created2017-07-10T00:51:36.000+0000
Updated2018-08-06T17:36:59.000+0000

Description

I am trying to implement the iOS 11 API DeviceCheck with Hyperloop, but it fails with 2.1.2 / 2.1.3 Beta 1 - The wrappers are simply not generated:
var DCDevice = require('DeviceCheck/DCDevice');

exports.generateToken = function(cb) {
	if (!DCDevice.current.isSupported) {
		Ti.API.info('iOS 11 DeviceCheck API not supported for this device, skipping ...');
		return;
	}
	
	DCDevice.current.generateTokenWithCompletionHandler(function(token, error) {
		if (error != null) {
			cb({ success: false, error: error.localizedDescription });
			return;
		}
		
		cb({ success: true, token: token });
	});
}

Comments

  1. Jan Vennemann 2017-09-06

    [~hknoechel], this seems to be an issue with multiple Xcode installs and wrong docs. First make sure to build using the -I 11.0 flag. After that the wrappers were generated for me. Also the docs for DCDevice seem to be outdated, DCDevice.current is wrong and it should be DCDevice.currentDevice. And last but not least it should be DCDevice.currentDevice.isSupported() because isSupported is the getter method for the supported property.
  2. Hans Knöchel 2017-09-15

    Resolving as Invalid with regards to the above comment
  3. Eric Merriman 2018-08-06

    Closing as invalid. If incorrect, please reopen.

JSON Source