Project: titanium
Issue TIMOB-23665: [Hyperloop] iOS: custom class is not added to Xcode project and compiled if no other frameworks are being used in the project
Creating a new project, enabling Hyperloop and adding a custom class does not work unless a Cocoa Touch framework is also referenced. Steps: * Create new project * Configure the project for Hyperloop * Add a custom Obj-C class '{{MyClass}}', declare it in {{appc.js}} and require it in {{index.js}} controller Result: * MyClass metabase JS file is generated * MyClass is not added to the Xcode project and therefore not compiled * No build-time error, run time error {{Cannot find class with name: MyClass}} I have tracked down the cause: Custom classes and frameworks are added to the Xcode project in the plugin {{updateXcodeProject}} function. This function makes this check for content in {{this.nativeModules}}: https://github.com/appcelerator/hyperloop.next/blob/master/iphone/plugin/hyperloop.js#L672. {{this.nativeModules}} is populated here: https://github.com/appcelerator/hyperloop.next/blob/master/iphone/plugin/hyperloop.js#L574. I have attached an example project which demonstrates the error.
Story points: 5