Dibish
Dibish

Reputation: 9293

How to run a sencha touch project in Xcode emulator

Am creating a App using sencha touch. Am testing the app using chrome, its working fine. Now am moving to Mac OS so i have to run the same app in Xcode to test . Dont know how to run the sencha project in xcode. Please direct me in right direction. Your help is much appreciate. Thanks in advance..

Upvotes: 1

Views: 1476

Answers (2)

Viswa
Viswa

Reputation: 3211

As described in phoegap doc

1) Download the latest release of PhoneGap

2) extract its contents

3) Move to phonegap-X.X.X/lib/ios

4) Drag the copied bin folder to the Terminal icon in your Dock, it should launch a new Terminal window

5) Type in ./create ~/Desktop/HelloWorld com.test.first HelloWorld then press "Enter"

~/Desktop/HelloWorld - this is where your project will.

com.test.first - package name

HelloWorld - project_name

6) Locate your new project folder that you just created (phonegap project).

7) Goto www folder and delete all files and folders within www folder except cordova.js.

8) Copy the content of your sencha project (copy the files in side sencha project, not project itself) and past the content of sencha project within www folder.

9) Open your index.html (this file from sencha project you just copied) file and include the cordova.js (this file will be there in www folder) file just like anyother js file.

<script type="text/javascript" src="cordova.js"></script>

10) Now open the project using xcode.

11) Run the project.

Upvotes: 1

Jake Lin
Jake Lin

Reputation: 11494

You need to use PhoneGap to host it. Have a look at PHONEGAP + XCODE4

Basically, create a PhoneGap project and put you sencha touch stuff in www folder.

Here is another article, which uses UIWebView rather than PhoneGap.

Upvotes: 1

Related Questions