Sessions at EuroPython 2011 about JavaScript

Your current filters are…

Monday 20th June 2011

  • JavaScript for Python Programmers

    by Jonathan Fine

    With the growth of AJAX and other client-side technologies many Python programmers, web-applications increasingly involve large amounts of JavaScript. Many of us find that, just to keep doing our job, we have understand JavaScript better.

    This tutorial, which was also given at EuroPython 2009 and 2010, provides an introduction to JavaScript that emphasises the similarities and differences between Python and JavaScript. It has a focus on the concepts underlying JavaScript, and in particular the object model and the lack of built-in classes. It also covers quite a few JavaScript gotchas and other traps for the unwary.

    Last year's course material is available online at
    http://jfine.bitbucket.org/docs/...

    This course is suitable for those who are Beginners or better in Python. Previous JavaScript knowledge is not required, but would helpful.

    At 5:45pm to 6:15pm, Monday 20th June

Wednesday 22nd June 2011

  • Objects and classes in Python (and JavaScript)

    by Jonathan Fine

    Python has a well-thought out system for classes. Beginners can use it without understanding it all. Experts can use it to produce code that is both elegant and powerful (such as models and class-based views in Django). Python classes can be used for many purposes.

    This tutorial arises from the author's experience in using classes to solve problems, such as:
    A. Add custom methods and attributes to objects that are, at root, just an integer.
    B. Construct dictionaries whose values are functions.
    C. Construct classes on-the-fly.
    D. Implement JavaScript object semantics in Python (advanced topic).

    The outline syllabus is:
    1. Review of the class statement in Python (and decorators).
    2. Subclassing built-in types such as int and tuple.
    3. How to define classes without using a class statement.
    4. How to define a dispatch dictionary using a class statement.
    5. Metaclasses as syntactic sugar for class construction.
    6. Metaclasses to provide new class semantics.
    7. Review of JavaScript object semantics.
    8. Using Python classes to implement JavaScript object semantics.

    For Guido on the history of Python classes see
    http://python-history.blogspot.c...
    http://python-history.blogspot.c...
    http://python-history.blogspot.c...

    This tutorial is for Intermediate or Advanced Python programmers. (Beginners will find it very hard going.) The aim of the course is to explain exactly what happens when a class in constructed, and to learn ways of using this knowledge.

    At 5:45pm to 6:15pm, Wednesday 22nd June

    Coverage video

Thursday 23rd June 2011

  • Objects and classes in Python (and JavaScript)

    by Jonathan Fine

    Python has a well-thought out system for classes. Beginners can use it without understanding it all. Experts can use it to produce code that is both elegant and powerful (such as models and class-based views in Django). Python classes can be used for many purposes.

    This tutorial arises from the author's experience in using classes to solve problems, such as:
    A. Add custom methods and attributes to objects that are, at root, just an integer.
    B. Construct dictionaries whose values are functions.
    C. Construct classes on-the-fly.
    D. Implement JavaScript object semantics in Python (advanced topic).

    The outline syllabus is:
    1. Review of the class statement in Python (and decorators).
    2. Subclassing built-in types such as int and tuple.
    3. How to define classes without using a class statement.
    4. How to define a dispatch dictionary using a class statement.
    5. Metaclasses as syntactic sugar for class construction.
    6. Metaclasses to provide new class semantics.
    7. Review of JavaScript object semantics.
    8. Using Python classes to implement JavaScript object semantics.

    For Guido on the history of Python classes see
    http://python-history.blogspot.c...
    http://python-history.blogspot.c...
    http://python-history.blogspot.c...

    This tutorial is for Intermediate or Advanced Python programmers. (Beginners will find it very hard going.) The aim of the course is to explain exactly what happens when a class in constructed, and to learn ways of using this knowledge.

    At 2:30pm to 6:30pm, Thursday 23rd June