{"id":332,"date":"2014-12-04T12:23:44","date_gmt":"2014-12-04T02:23:44","guid":{"rendered":"http:\/\/clould.com.au\/?p=332"},"modified":"2015-02-20T04:20:03","modified_gmt":"2015-02-19T18:20:03","slug":"frameworks","status":"publish","type":"post","link":"https:\/\/clould.com.au\/?p=332","title":{"rendered":"Frameworks"},"content":{"rendered":"<p>I am often asked why we created RapidOS instead of only using AngularJS, KnockoutJS or NodeJS. \u00a0This is a good question and given the number of companies that have adopted these frameworks one could legitimately believe they are the best option for all solutions. \u00a0This however isn&#8217;t the case and with every solution there are pros and cons to every approach. \u00a0There also is no right or wrong way of doing things, with everyone having their own opinions &#8211; here are mine.<\/p>\n<p><strong>RapidOS<\/strong><\/p>\n<p>RapidOS is a closed source client + server (both separable) framework for creating RIAs (Rich Internet Applications). \u00a0Over 33,000 users World Wide use products based upon the RapidOS framework! \u00a0RapidOS isn&#8217;t an exclusive framework meaning that it can co-exist with others, in fact it has inbuilt support for AngularJS and others with full MDI, SDI and lazy loading support out of the box.<\/p>\n<p>Previous articles on how RapidFMS can add value to your business: \u00a0<a href=\"http:\/\/clould.com.au\/?p=136\">10 ways<\/a> + <a href=\"http:\/\/clould.com.au\/?p=171\">7 more ways<\/a><\/p>\n<p>Some of the requirements that the framework we needed were that are currently fulfilled by RapidOS:<\/p>\n<ul>\n<li>Security, Multi-User, Multi-Device<\/li>\n<li>Multi-Monitor support<\/li>\n<li>Paired Devices, including cross device notifications<\/li>\n<li>Printing (local direct to printer, remote printing and printing from mobile devices)<\/li>\n<li>SDI &amp; MDI Forms<\/li>\n<li>Plays well with 3rd party code<\/li>\n<li>Modular<\/li>\n<li>Supports dependancy injection including itself so it&#8217;s easily replaceable<\/li>\n<li>Works &#8216;on&#8217; Android<\/li>\n<li>Works on the majority of hosting providers<\/li>\n<li>Compatibility across multiple browsers<\/li>\n<li>Supports non-browsers<\/li>\n<li>run Fast regardless of project size<\/li>\n<li>have a low learning curve and easy to use for all skill levels<\/li>\n<\/ul>\n<p><strong>AngularJS<\/strong><\/p>\n<p>AngularJS is an Open Source client-side only framework. \u00a0When it first came out was quite cutting edge. \u00a0It actually allows for some solutions to be developed with very little coding. \u00a0It does this by offering features such as automatic two-way binding, extending HTML to the point that application logic is mixed into the actual HTML via such things as filters as well as quite a powerful templating engine.<\/p>\n<p>To do what it does isn&#8217;t without issues though:<\/p>\n<ul>\n<li>AngularJS doesn&#8217;t usually play well with other frameworks, it provides a method to sandbox your custom non-AngularJS-friendly code if you have any but sometimes you just cannot sandbox other 3rd party code the AngularJS way.<\/li>\n<li>If you put logic into your HTML then your separation of concerns patterns are broken.<\/li>\n<li>AngularJS to offer the 2-way binding really does some cool magic internally but it isn&#8217;t always what you want either and the AngularJS code itself is very complex &#8211; the AngularJS community has created their own patterns or common solutions to this problem.<\/li>\n<li>It has 2-way binding but only single monitor support, nor does it support device pairing within it&#8217;s binding.<\/li>\n<li>Performance is not great for large applications.<\/li>\n<li>AngularJS is developed by Google. \u00a0I like Google products, but&#8230; they have a very good track record of dropping or deprecating products with little warning. \u00a0To some credit they&#8217;ve Open Sourced this one so relying your business on this is not as bad as some of Google&#8217;s other products they have dropped in the past.<\/li>\n<li>Dependancy Injection is an offered feature of AngularJS but it doesn&#8217;t provide the ability to Inject something other than AngularJS to test your code in isolation of AngularJS. \u00a0Not only does this make it sometimes difficult to isolate issues as to whether they are caused by AngularJS or your code, it also means it&#8217;s very difficult to replace AngularJS with an alternative should you require without re-writing your code. \u00a0AngularJS would become your biggest dependancy yet it&#8217;s not injectable?<\/li>\n<li>Given AngularJS&#8217;s complexity the documentation is not as good as it should be.<\/li>\n<\/ul>\n<p><em>Out of the box, of our requirements, AngularJS provides:<\/em> Works &#8216;on&#8217; Android, Works on all hosting providers, Compatibility across multiple browsers<\/p>\n<p>Comment: only use it for projects that exist already using it<\/p>\n<p><strong>KnockoutJS<\/strong><\/p>\n<p>Knockout is an Open Source client-side only framework. Knockout has been around some time and although it offers some of the cool features of AngularJS, it does things in a more traditional way. \u00a0Knockout however does still promote the use of logic in HTML but not to the extent of AngularJS. \u00a0Knockout provides looping constructs, filters, event bindings (as does AngularJS) but to me Knockout&#8217;s solution is somewhat more elegant but not as elegant as it could have been. \u00a0What is interesting with KnockoutJS though is it&#8217;s labelled a framework but doesn&#8217;t really offer a lot out of the box. \u00a0It&#8217;s a bit like Mustache or Handlebars on steroids &#8211; maybe more like jQuery+Handlebars on steroids. \u00a0This is not necessarily a bad thing, but it means a LOT more is necessary to create a working application. \u00a0Generally because KnockoutJS doesn&#8217;t try to be more than it is, it has less issues than AngularJS.<\/p>\n<p>To do what it does isn&#8217;t without issues though:<\/p>\n<ul>\n<li>If you put logic into your HTML then your separation of concerns patterns are broken.<\/li>\n<li>It has 2-way binding but only single monitor support, nor does it support device pairing within it&#8217;s binding.<\/li>\n<li>Because of lack of scoping or contexts, without some good up-front design a large application is easily confused.<\/li>\n<li>Although KnockoutJS doesn&#8217;t offer much in the way of Dependancy Injection, and although it is less complex than AngularJS, it is still quite complex. It also means it&#8217;s very difficult to replace KnockoutJS with an alternative should you require without re-writing your code.<\/li>\n<\/ul>\n<p><em>Out of the box, of our requirements, KnockoutJS provides:<\/em>\u00a0Plays well with 3rd party code, Works &#8216;on&#8217; Android, Works on all hosting providers, Compatability across multiple browsers, run Fast regardless of project size, have a low learning curve and easy to use for all skill levels<\/p>\n<p>Comment: not a bad choice for new or existing projects if you require 2 way binding with it&#8217;s limitations and don&#8217;t mind the few issues noted<\/p>\n<p><strong>NodeJS<\/strong><\/p>\n<p>NodeJS isn&#8217;t a framework, it&#8217;s really a platform or a Web Server. \u00a0It is fast performing and based on Google&#8217;s very fast V8 JavaScript engine allows you to write server-side code in JavaScript. \u00a0This also opens up the ability of sharing code between your client and server easily. \u00a0Unfortunately for the time being it doesn&#8217;t run on Android and also not every hosting provider supports it.<\/p>\n<p>Comment: I can&#8217;t wait for an Android version to eventuate<\/p>\n<p><strong>Other Awesome Frameworks<\/strong><\/p>\n<p>Here are some other notable frameworks that are very good and worthwhile keeping an eye on.<\/p>\n<p><a href=\"https:\/\/www.meteor.com\/\">Meteor<\/a> &#8211; this I think blows AngularJS away, however it&#8217;s in it&#8217;s early stages having just released version 1.0. \u00a0Both a client and server-side Open Source framework and it works &#8216;on&#8217; Android &#8216;and&#8217; IOS. \u00a0It mixes the best of NodeJS and Angular but it also a complex beast internally. \u00a0What is good though they have tried to keep it simple for the developer.<\/p>\n<p><em>Out of the box, of our requirements, Meteor provides:<\/em>\u00a0Multi-User, Multi-Device, \u00a0it achieves in a way Multi-Monitor support,\u00a0it achieves in a way Paired Devices including cross device notifications, Works &#8216;on&#8217; Android,\u00a0Compatibility across multiple browsers,\u00a0have a low learning curve and easy to use for all skill levels<\/p>\n<p><a href=\"http:\/\/somajs.github.io\/somajs\/#\/\">Soma.js<\/a>\u00a0&#8211; Soma is an Open Source client only framework and has been around a little while now. Of all the frameworks I&#8217;ve used is one of the most elegant and nicely structured. \u00a0It provides some of the features of AngularJS and KnockoutJS but doesn&#8217;t force anything down your throat. \u00a0You don&#8217;t have to use the templating, you don&#8217;t need to confirm to a strict project structure. \u00a0<strong>Highly recommended!<\/strong><\/p>\n<p><em>Out of the box, of our requirements, Soma provides:<\/em>\u00a0Plays well with 3rd party code,\u00a0Modular,\u00a0Supports dependancy injection including itself so it&#8217;s easily replaceable,\u00a0Works &#8216;on&#8217; Android,\u00a0Works on all hosting providers,\u00a0Compatibility across multiple browsers,\u00a0Supports non-browsers,\u00a0run Fast regardless of project size,\u00a0have a low learning curve and easy to use for all skill levels<\/p>\n<p><a href=\"http:\/\/backbonejs.org\/\">Backbone.js<\/a> &#8211; Backbone is a very established Open Source JavaScript framework that can work on either client or server-side which provides an extensive library of useful functions as well as the ability to create models and respond to changes including automatic updating of DOM. \u00a0What is good about backbone is that it doesn&#8217;t force anything upon you and you can pick and choose which features to use and the model listeners aren&#8217;t restricted to updating only DOM.\u00a0<strong>Highly recommended!<\/strong> if you need it&#8217;s features.<\/p>\n<p><em>Out of the box, of our requirements, Backbone provides:<\/em>\u00a0Plays well with 3rd party code,\u00a0Works &#8216;on&#8217; Android,\u00a0Works on all hosting providers,\u00a0Compatibility across multiple browsers,\u00a0Supports non-browsers,\u00a0run Fast regardless of project size,\u00a0have a relatively low learning curve and easy to use for all skill levels<\/p>\n<p><strong>Mixing and Matching Frameworks<\/strong><\/p>\n<p>To overcome limitations of each framework, mixing and matching frameworks can be a good option. RapidOS&#8217;s approach is to sandbox other libraries and frameworks including AngularJS so most if not all the the features can co-exist with both RapidOS and those other frameworks. \u00a0This approach gives out of the box support of all RapidOS features to an AngularJS application &#8211; or to be more accurate, all of AngularJS&#8217;s features to an RapidOS application.<\/p>\n<p>JC<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I am often asked why we created RapidOS instead of only using AngularJS, KnockoutJS or NodeJS. \u00a0This is a good question and given the number of companies that have adopted these frameworks one could legitimately believe they are the best option for all solutions. \u00a0This however isn&#8217;t the case and with every solution there are <a href='https:\/\/clould.com.au\/?p=332' class='excerpt-more'>[&#8230;]<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/clould.com.au\/index.php?rest_route=\/wp\/v2\/posts\/332"}],"collection":[{"href":"https:\/\/clould.com.au\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/clould.com.au\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/clould.com.au\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/clould.com.au\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=332"}],"version-history":[{"count":13,"href":"https:\/\/clould.com.au\/index.php?rest_route=\/wp\/v2\/posts\/332\/revisions"}],"predecessor-version":[{"id":346,"href":"https:\/\/clould.com.au\/index.php?rest_route=\/wp\/v2\/posts\/332\/revisions\/346"}],"wp:attachment":[{"href":"https:\/\/clould.com.au\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=332"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/clould.com.au\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=332"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/clould.com.au\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=332"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}