SAP UI5 sap-ui-core.js loading logic

Created by Wang, Jerry, last modified on May 09, 2016

If writing this is possible,
yes. This approach is to load sap-ui-core.js this important document by the absolute path.
If this mode is changed to a relative path:

Someone made you exactly the same problem and on SCN. You have a problem and to make good use scn :) Google
http://scn.sap.com/thread/3506469
Press F12 to open development tool, able to see the sap-ui-core.js in the Sources tab.

So if I use the local tomcat run ui5 program, I know how this sap-ui-core.js from where the local load it?
You can use the Chrome development tool in the Network tab, enter the sap-ui as a filter:

Then click one of the files, you can find the answer at http response of field x-sap-ResourceUrl years.

You go to your local folder to find, see if I can find this file?

You will find this folder just temp folder, this is when you run as server, Eclipse, Eclipse automatically UI5 core library in the js solution out on the temp folder used for loading.

But this is only our development in Eclipse, and the circumstances do unit testing. If customers use our UI5, not loaded sap-ui-core.js this way. You learn specific ways and so on after the board, since this requires knowledge of the netweaver.

You asked about the Servlet web.xml in on some knowledge:

你可以随便用关键字tomcat+Servlet搜索一些文章来看。
我自己也写过一篇:http://scn.sap.com/community/developer-center/front-end/blog/2014/12/04/explore-the-comsapui5resourceresourceservlet

要获取更多Jerry的原创文章,请关注公众号"汪子熙":

Guess you like

Origin www.cnblogs.com/sap-jerry/p/12158406.html