the beauty and the beast - modern javascript development with angularjs and plone

33
The Beauty and the Beast Modern Javascript Development with AngularJS and Plone Timo Stollenwerk Plone Conference 2014 — Bristol

Upload: plone-foundation

Post on 23-Jun-2015

716 views

Category:

Internet


1 download

DESCRIPTION

Learn how a modern, full-featured Javascript front-end framework can play well with an enterprise-class content management system. This talk will present how we build a flexible AngularJS front-end solution on top of Plone, with a state-of-the-art Javascript development workflow.

TRANSCRIPT

Page 1: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

The Beauty and the BeastModern Javascript Development

with AngularJS and Plone

Timo StollenwerkPlone Conference 2014 — Bristol

Page 2: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

The State of Javascript in Plone

Page 3: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Problems

Page 4: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Requirements

Page 5: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Modern Javascript Solutions

Page 6: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Angular JS

Page 7: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

0

300

600

900

1200

Angular Backbone Ember Knockout React

Contributors

Page 8: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

0

5

10

15

20

Angular Backbone Ember Knockout React

Books

Page 9: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

0

75

150

225

300

Angular Backbone Ember Knockout React

Meetups

Page 10: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Google Trends

Page 11: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

„We're not building a new language, just making what we already have better“

!

— @mhevery

Page 12: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Zope Browser View

def persons(self): return [ {'title': 'John Doe'}, {'title': 'Jane Doe'} ]

Page 13: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

<ul> <li tal:repeat="person view/persons"> <span tal:replace="person['title'}"/> </li> </ul>

Zope Page Template

Page 14: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

$scope.persons = [ {'title': 'John Doe'}, {'title': 'Jane Doe'} ]

Angular Model / Controller

Page 15: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

<ul> <li ng-repeat="person in persons"> {{person.title}} </li> </ul>

Angular Template

Page 16: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

<ul> <li tal:repeat="person view/persons"> <span tal:replace="person['title'}"/> </li> </ul>

Zope Page Template

Page 17: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Angular Templates

<input type="text" ng-model="yourName"> !<h1>Hello {{yourName}}!</h1>

Page 18: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Two Way Binding

Page 19: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Two Way Binding

<input type="text" ng-model="yourName" placeholder="Your name here"> !

<h1>Hello {{yourName}}!</h1>

Page 20: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone
Page 21: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Angular Directives

!<portlet-navigation start-level="1" tree-depth="2" />

Page 22: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone
Page 23: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Dependency Injection

myApp.controller('MyUsers', function(getUsersService) { /* Do something with myUserService */ $scope.users = getUsersService(); } );

Page 24: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Demo

Page 25: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone
Page 26: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Modern Javascript Development

Page 27: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone
Page 28: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

The Future of Plone?

Page 29: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

The Future of Plone?

github.com/tisto/plone.app.angularjs

Page 30: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

RESTful JSON API

Page 31: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Reasons not to use Javascript

Page 32: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

Conclusion

Page 33: The Beauty and the Beast - Modern Javascript Development with AngularJS and Plone

The Beauty and the BeastModern Javascript Development

with AngularJS and Plone

Plone Conference 2014 — Bristol

Timo Stollenwerk http://timostollenwerk.net

[email protected] irc: tisto

!github.com/tisto/plone.app.angularjs