Skip to Content
avatar image
Former Member

Packaging a sapui5 app with phonegap

Hi,

Is there anyone who knows how to structure of my project has to be in order to package it with phonegap? When you make a sapui5 application with eclipse, the libraries are not stored in the project. When you want to package the application, you need those.

Btw, I package my app using this website: https://build.phonegap.com/

Thanks

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

6 Answers

  • Best Answer
    Jan 04, 2013 at 08:34 AM
    10

    Hi Robbe,

    basically you need the "sapui5-static.zip" from the SDN evaluation version (SAPUI5 as a file tree) and unzip it to a location in your project close to your HTML file.

    This file is (zipped) 28.4 MB large - too large for reasonable mobile apps - but contains A LOT of stuff which is not needed at runtime and also many duplicate files in different versions (like debug plus optimized, single control files plus merged library files plus library preload files,...).

    For the new "sap.m" mobile library an optimized package (< 2 MB) might be provided soon, but with some manual deletion you can also quickly get below 5 MB (for the sap.m library - when you are using other libraries, the steps and the resulting size are different:

    From sapui5-static.zip, delete:

    /test-resources/*

    /discovery/*

    /resources/sap-ui5-dbg.js

    /resources/sap-ui-core-all-dbg.js

    /resources/sap/uiext/* 

    /resources/sap/service/* 

    if you don't need them the /resources/sap/makit and/or /resources/sap/viz chart libraries

    and in /resources/sap/ui/ the following library folders (when you wantto use sap.m, otherwise adapt your deletion):

    commons

    qunit

    richtexteditor

    table

    test

    ux3

    There is also some PhoneGap-related documentation here:

    https://sapui5.netweaver.ondemand.com/sdk/#docs/guide/WebContainer.html

    Regards

    Andreas

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 24, 2013 at 01:53 PM

    Hi,

    I just noticed I have an update for this. For hyprid apps there is now a streamlined zip file contained in the SCN version of SAPUI5: "mobile-static.zip" (or "mobile-static-opt.zip").

    It is roughly 4 MB large in version 1.16 but still contains debug plus optimized version of all files, two themes, and some other extra stuff, so it can be stripped down further. On the other hand you may want to add a certain control library. So basically it is an "as good as possible" starting point for manual adaptation.

    There is some documentation on these adaptations at http://veui5infra.dhcp.wdf.sap.corp:8080/demokit/#docs/guide/WebContainer.html (this one refers to 1.14, but if you deploy your own SDK demokit from SCN you should find the current version, which is not vastly different).

    Andreas

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Apr 06, 2013 at 07:55 AM
    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jun 08, 2015 at 08:46 AM

    Hi,

    I have created an SAPUI5 Project with data coming from different SAP Gateway Server.

    Now i have integrated it into the Phonegap Project as i have done for different project.

    But the data is not coming in the Mobile APP.

    Screen is rendered without data.

    Could you please help me with the same?..

    Thanks & Regards:

    Azhar

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 07, 2014 at 04:13 AM

    Hey friend, @Andreas Kunz

       As You Mentioned above I have copied my Static folder into my Project Near to my Index.html file ( In the Web Content) After copying What We must do ?? 😔

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 10, 2014 at 09:31 AM

    Hi,

    Even I'm getting similar error. The view is not being displayed . I'm getting a blank page

    I have copied the resource folder as specified.

    Error message is: Failed to preload 'sap.m.library-preload'

    Can someone help me with this

    Thanks in advance


    err.PNG (48.7 kB)
    Add comment
    10|10000 characters needed characters exceeded