Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 10519

Re: SAPUI5 code reuse: fragments vs. controls vs. views

$
0
0

Hi Dominik,

 

Fragments, Views and Controls are not related to each others.

 

SAPUI5 Views : Views are nothing but the application pages. We define our our user interface by creating Views. Views is formed or created by using one or more Contrlols in it say Page,SimpleForm,Dialog,Label,Input etc. . Every view has its own controller.

 

SAPUI5 Controls : Controls the UI elements provided by the SAPUI5 framework. for example  Page,SimpleForm,Dialog,Input,

 

Fragments:Fragments are the pieces of UI just like SAPUI5 Views. Whenever we need to use some similar UI parts many times in our application/views we create Fragments of those UI parts because Fragments are reusable and are light weight compared to VIews and Controls. Fragments are stored with in the application itself and can be used by that application only. Fragments are defined as View only and calling Views controller is shared with Fragment as Fragments are not having their own controllers.

 

I have written one blog for reusing UI elements with fragments for more details:

Click Here

 

SAPUI5 Components:  SAPui5 Components and Fragments are similar but components are reusable and INDEPENDANT parts used in SAPUI5 Applications.An SAPUI5 applications can use components stored on some other locations from where applications is running
Note : Components concept is under development so its advisable not to use it because it may change completely in future.

 

I hope above information cleared your doubts 

 

Regards,

Rauf


Viewing all articles
Browse latest Browse all 10519

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>