Alfresco Front End Development - From JSF to Angular2

Seed have been working with Alfresco for many years and have experienced all of the iterations of Alfrescos browser based apps to date.  This Blog discusses the history of frameworks used and the latest announcement on the use of Angular2 for future Alfresco based applications.

History

We were around for version 1.0 of Alfresco when the Desktop Client was the main interface for Alfresco which was written using JSF.   Alfresco followed up the Desktop Client with Share.  Share was a big step forward, embracing Javascript and based on Surf.  Surf is Alfresco’s  own front end framework based on Spring MVC.  It allowed pages to include regions and components. Components displayed information about content, encapsulating functionality,  with the ultimate aim of being able to include a  component in different regions on numerous pages.  Surf also embraced the use of REST webscripts to retrieve and format the data for the components to display.   Surf was a good idea in itself although it is pretty cumbersome because there are so many files involved in setting up a page.  The main example of the use of Surf of course is with Share.  This is where to my mind Alfresco really went wrong because although Share was built around Surf, the Share implementation used many embedded javascript files to glue it together and do the actual presentation manipulation.  To make matters worse, with every iteration of Share they would change Surf.  To be honest, by the time we got to version 4.2 our customers were asking us why they had to redo Share customisations between each upgrade.   Seed were not the only one who felt this. The community had been grumbling for quite some time too.

Aikau

Alfresco have never been one to sit on their laurels so it was great that with the 4.2 release of Share Aikau was introduced.   The main purpose of Aikau is to provide a library of widgets that can be easily assembled into a web application for accessing an Alfresco repository.    What this means is that you can now build Share pages and specify the included widgets you want to display.  Each widget is encapsulated their function, styling and localised behaviour.  Aikau is based on DOJO and AMD.  It is one step closer to developing applications using a standard, proven, javascript approach.  Currently Alfresco Share is being updated to include more and more Aikau components and pages.   A final note on the history of front ends at Alfresco,  two years ago Alfresco decided they wanted to get into the Content Application space.  As part of that they decided to create a new front end framework designed for the cloud known as Sparta.  It was meant to be configurable and a platform that partners could develop their own applications against.  At Seed this is the direction we believe in, most of our customers are running their instances in the cloud and we think it is only a matter of time before SAAS ECM takes over the market.  Unfortunately it got off to a spluttering start with the framework being scrapped after 18 months of development.

Angular2

9 months ago we decided to look for an independent front end framework that would allow us to both extend Share and also build content driven applications that we could host anywhere.  We decided on Angular2.  Thus far we have developed a number of small standalone applications on angular2 that interact with Alfresco.  It was fantastic to see that a few months ago at Beecon that Alfresco also announced that they were going the Angular2 direction for new front end application developments.  Alfresco have created a github repository with sample Angular2 components here to get you started.  Over the next few months we will create a number of Blogs on our learning and understanding of Angular2 and how you can use it to build Content Centric Angular applications that connect to Alfresco.