<!DOCTYPE HTML>
<html style="height: 100%;">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta charset="utf-8">
<title>Demo</title>
<script id="sap-ui-bootstrap"
src="https://openui5.hana.ondemand.com/resources/sap-ui-core.js"
data-sap-ui-libs="sap.m"
data-sap-ui-theme="sap_belize"
data-sap-ui-compatVersion="edge"
data-sap-ui-preload="async"
data-sap-ui-resourceRoots='{"demo": "./"}'>
</script>
<script>
sap.ui.getCore().attachInit(function() {
new sap.ui.core.ComponentContainer({
name: "demo",
height: "100%"
}).placeAt("content");
});
</script>
</head>
<body class="sapUiBody" id="content">
</body>
</html>
{
"_version": "1.5.0",
"start_url": "index.html",
"sap.app": {
"id": "demo",
"type": "application",
"title": "foo",
"applicationVersion": {
"version": "1.0.0"
}
},
"sap.ui": {
"technology": "UI5",
"deviceTypes": {
"desktop": true,
"tablet": true,
"phone": true
}
},
"sap.ui5": {
"dependencies": {
"minUI5Version": "1.40.0",
"libs": {
"sap.m": {}
}
},
"contentDensities": {
"compact": true,
"cozy": false
},
"rootView": {
"viewName": "demo.App",
"type": "XML",
"height": "100%"
}
}
}
<mvc:View xmlns="sap.m" xmlns:mvc="sap.ui.core.mvc" displayBlock="true">
<App id="myApp">
<Page title="Hello ...">
<Title text="{core>/world}" titleStyle="H1"/>
</Page>
</App>
</mvc:View>
// Instantiate the view via the app descriptor or call sap.ui.xmlview below.
// Replace "sap.ui.getCore()" with "this" to enable data binding for the view instantiated by component metadata or app descriptor.
sap.ui.define([
"sap/ui/core/UIComponent",
"sap/ui/model/json/JSONModel",
], function(UIComponent, JSONModel) {
"use strict";
return UIComponent.extend("demo.Component", {
/*----------------------------*/
metadata: { manifest:"json" },
/*----------------------------*/
init: function() {
UIComponent.prototype.init.apply(this, arguments);
/*----------------------------*/
// sap.ui.xmlview({viewName : "demo.App"}).placeAt("content");
/*----------------------------*/
sap.ui.getCore().setModel(new JSONModel({
"world": "World!"
}), "core");
}
});
});