Front End Developers: Pyjamas

Post on 12-May-2015

732 views 0 download

Tags:

description

A quick presentation about the merits of using Pyjamas framework for front end development.

Transcript of Front End Developers: Pyjamas

pyjamas

Great... yet another web development framework

What is Pyjamas?

• A Python framework for writing web front end

What is Pyjamas?

• A Python framework for writing web front end

What?!

What is Pyjamas?

• A Python framework for writing web front end

• You don't even need Javascript, write everything in Python

What is Pyjamas?

• A Python framework for writing web front end

• You don't even need Javascript, write everything in Python

• It will automatically convert your code to Javascript (and even take care of cross-browser issues)

Why Python?

Why Python?

• Not that different from Javascript

Why Python?

• Not that different from Javascript

• Very clean syntax

Javascript Python

&& and

|| or

! not

{ }

;

var temp=a;a=b;b=temp; a, b = b, a

if(1<a && a<5) { if 1<a<5:

Why Python? (cont.)

• Only one way to do things (usually)

Why Python? (cont.)

• Only one way to do things (usually)

• Already a very popular backend language

Why Python? (cont.)

• Only one way to do things (usually)

• Already a very popular backend language

• Makes JS debugging feel like FORTRAN

Why Python? (cont.)

• Only one way to do things (usually)

• Already a very popular backend language

• Makes JS debugging feel like FORTRAN

Customary Hello World example:

print ”Hello World”

Why Python? (cont.)

Sorting a list:

Why Python? (cont.)

 function bubbleSort(items) {   var x, y, holder;    // The Bubble Sort method    for(x = 0; x < items.length; x++) {     for(y = 0; y < (items.length-1); y++) {       if(items[y] > items[y+1]) {         holder = items[y+1];         items[y+1] = items[y];         items[y] = holder;       }   }}

 def bubbleSort(items):

  # The Bubble Sort method      for x in range(len(items)):    for y in range(len(items)-1):      if items[y] > items[y+1]:        items[y], items[y+1] =\        items[y+1], items[y]

Javascript Python

Why Python? (cont.)

Javascript Python

Better way of sorting it:

items.sort() items.sort()

What can Pyjamas do?

What can Pyjamas do?

• Anything JS or Python can (in theory)

What can Pyjamas do?

• Anything JS or Python can (in theory)

• Manipulate the DOM

What can Pyjamas do?

• Anything JS or Python can (in theory)

• Manipulate the DOM

• Coexist with other JS on same page

What can Pyjamas do?

• Anything JS or Python can (in theory)

• Manipulate the DOM

• Coexist with other JS on same page

• It's a Python version of GWT

Who uses it?

Who uses it?

• pyjs.org pyjamas

Who uses it?

• pyjs.org

• grafpad.com

pyjamas

Who uses it?

• pyjs.org

• grafpad.commy web app

pyjamas

Who uses it?

• pyjs.org

• grafpad.com

• gbsware.com

my web app

pyjamas

Questions?

Feel free to contact me(questions, support, web development):

alex@pyjeon.com@ATsepkov

@Pyjeon

Pyjeon Software LLC