modernizing a legacy code base via angular
Post on 08-Jul-2015
154 Views
Preview:
DESCRIPTION
TRANSCRIPT
Modernizing aLegacy Code Base via
Florian Benz / @flbenz
June 26, 2014
Initial SituationServerside rendering
A bit of jQuery
GWT for some features
Order HistoryList of orders
Order HistoryConfirm that goods arrived
Use Angular Selectively
<html ng-app="myMercateoApp" ...>
<div ng-controller="OrderListCtrl">
nginitServerside configuration
<tbody ng-controller="OrderRowCtrl" ng-init="orderId='90918130'">
nginclude Cache
<div ng-include="'.../ArticleList.jspf'"></div>
<script type="text/ng-template" id=".../ArticleList.jspf"> <div ng-controller="ArticleListCtrl"> ... </div></script>
nginclude CacheIncluding is required
<hash>.mercateoApp.js possible
But not for JSP / JSPF
Directives as WrappersjQuery UI Plugins
Caution: interfering DOM manipulations
Other IssuesAchieve unobtrusive JavaScript
IE7
i18n / l10n
WorkflowJust call Grunt from other build tools
Bower, Karma, Jasmine, ...
TypeScript= JavaScript
+ ES6
+ optional typing
Thank you!@flbenz
fbenz.net
top related