Purpose of Staging folder in PhoneGap 3.4? Only changes to index.html in this folder get recognized?

前端 未结 4 1319
臣服心动
臣服心动 2020-12-17 01:05

We noticed a Staging folder that appears in Xcode\'s Project Navigator after creating a project with PhoneGap 3.4. This Staging folder didn\'t appe

4条回答
  •  独厮守ぢ
    2020-12-17 01:19

    The contents of "Staging" folder actually goes into execution on your device.

    myAwesomeProject/www ---copy---> Staging/www
    

    Cordova's build command copies contents from your "myAwesomeProject/www" folder to the "Staging/www" folder. The commands are:

    sudo cordova build ios  //ios build
    sudo cordova build android //android build
    

    Caution! Remember that the build command not only copies the contents to the "Staging" folder but also build the whole app including native ios/android code. So, it will take long. For minor changes I usually copy the changed files to the "Staging" folder manually and build and run the app using XCODE incase of iOS.

提交回复
热议问题