上一个练习,做了一个简单但是完整的Web应用,使用HTML5技术实现的。
今天做个更加有趣的小练习,现在我再通过Apache Cordova来将其封装为iOS上的移动应用。
我们可以看到基本上不需要做任何修改就可以迁移到iOS平台上了。
Cordova就是以前的PhoneGap。
主页地址:https://cordova.apache.org/
1.安装Cordova
我这里安装的cordova 3.0.6
2.创建一个项目Apache Cordova 项目,名称叫employee
cordova -d create ~/Documents/CordovaProjects/employee com.sample employee
增加对iOS的支持:
cordova -d platform add ios
3.下载sapui5的包,解压缩后将resource文件夹拷贝到employee/www下
4.修改一下index.html
<!DOCTYPE html>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may n