4. — Responsive Web Design is difficult to apply for web apps
— No truly cross-platform high-level frameworks on the market
share
— It's difficult to provide the necessary level of UX
for each of the platforms
10. Assumptions
— In most cases, considering the device types, all the changes are
in layout
— Logic is just customizable
— User does not need everything from the start
— You can cheat user // Optimistic Interfaces
11. What if…
— Make modules (components) truly independent
— Load them lazily
— Choose the necessary template based on device type
— Customize logic of the component based on device type
16. XF Module — a part of the framework,
e.g. xf.touch.js, xf.view.js, xf.router.js, etc.
!
All current modules are included in standard
build of XF. Not all modules are required.
17. XF Component — a building block of app
(~widget), that can be abstracted as an
independent unit and can be reused throughout
the app or even any other XF app.
!
Includes collection (w/ models) and view.
18. XF UI Element — a page element without any
data connection, e.g. button, range controller,
scrollable area, list, etc.
!
UI Elements have simplified markup, that is
parsed by XF to make them look and feel in the
proper way.
21. — Lazy loading, registering and creation of components
— Event bus and proxy
— Getters/setters for component options
— Starting the app and initialization of other xf.modules
24. var _oldshow = $.fn.show;
/** @ignore */
$.fn.show = function(speed, callback) {
var res = _oldshow.apply(this, arguments);
if ($(this).find('[data-component]').length)
XF.trigger('xf:loadChildComponents', this);
return res;
};
— Hooks that trigger loading of components when some area
become visible, e.g.:
48. Q of deferred events
// if component is not loaded or constructed
// events will wait until it will be
!
XF.trigger('component:componentID:eventName');
!
XF.trigger('component:componentClass:eventName');
53. Write less…
ul data-role=listview
li data-role=dividerA/li
li
h2Header/h2
pNo link/p
/li
lia href=#Simple link/a/li
li data-role=dividerDivider/li
li
h2Header/h2
pHeader and description/p
/li
/ul
54. …do nothing
ul data-role=listview data-skip-enhance=true id=xf-8293 class=xf-listview
li class= xf-li xf-li-dividerA/li
li class=xf-li-static xf-li
div class=xf-li-wrap
h2 class=xf-li-headerHeader/h2
p class=xf-li-descNo link/p
/div
/li
li class= xf-li
a href=# class=xf-li-btn
Simple link
div class=xf-btn-text/div
/a
/li
li class= xf-li xf-li-dividerDivider/li
li class= xf-li
a href=# class=xf-li-btn
div class=xf-btn-text
h2 class=xf-li-headerHeader/h2
p class=xf-li-descHeader and description/p
/div
/a
/li
/ul