annotate source/europython-2010-tutorial.rst @ 48:d3ef1c9d4ca2

europython-2010-tutorial.rst: spidermonkey-bin not in Ubuntu 10.4.
author Jonathan Fine <jfine@pytex.org>
date Mon, 12 Jul 2010 09:27:05 +0100
parents 630e8132250e
children e0b35ddff586
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
41
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
1 EuroPython 2010 Tutorial
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
2 ========================
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
3
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
4 Time, date and location
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
5 -----------------------
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
6
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
7 This tutorial will take place on Saturday 17th July, from 2pm to
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
8 5.45pm in Lecture Room 2, the Birmingham Conservatoire, Birmingham,
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
9 UK.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
10
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
11
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
12 Installed software
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
13 ------------------
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
14
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
15 Participants should bring with them a laptop computer with the
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
16 following installed:
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
17
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
18 1. The Firefox web browser, with the Firebug add-on.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
19
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
20 2. A programmer's editor, preferably with a JavaScript mode.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
21
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
22 3. A command line JavaScript interpreter.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
23
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
24 * For Linux I suggest SpiderMonkey.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
25
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
26 .. code-block:: bash
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
27
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
28 $ sudo apt-get install spidermonkey-bin # Ubuntu
48
d3ef1c9d4ca2 europython-2010-tutorial.rst: spidermonkey-bin not in Ubuntu 10.4.
Jonathan Fine <jfine@pytex.org>
parents: 41
diff changeset
29
d3ef1c9d4ca2 europython-2010-tutorial.rst: spidermonkey-bin not in Ubuntu 10.4.
Jonathan Fine <jfine@pytex.org>
parents: 41
diff changeset
30 (No longer, I'm told, available for Ubuntu 10.4.)
41
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
31
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
32 * For Windows and Mac I suggest JSDB, from
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
33 http://www.jsdb.org/download.html. It also works on Linux.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
34
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
35 4. This documentation, downloaded from
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
36 `Bitbucket downloads <http://bitbucket.org/jfine/javascript-for-python-programmers/downloads>`_.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
37
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
38 5. The Python documentation, download from
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
39 `Python docs site <http://docs.python.org/download.html>`_.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
40
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
41
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
42 Timetable
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
43 ---------
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
44
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
45 The tutorial consist of two 90 minutes sessions, separated by a 15
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
46 minute break.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
47
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
48 I hope to run six sessions, each 30 minutes long. I hope each session
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
49 will be 15 minutes of me talking followed by 15 minutes of
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
50 programming.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
51
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
52 The topics I'm intending to cover are
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
53
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
54 We start at 2pm prompt, with software already installed if possible.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
55
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
56 1. Demonstration and discussion of the counters example application.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
57
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
58 2. JavaScript gotchas.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
59
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
60 3. Objects and inheritance, class basics.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
61
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
62 Here we have a 15 minute break.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
63
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
64 4. JavaScript's *this* pseudo-variable (including *call* and *apply*).
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
65
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
66 5. Closures, modules and memory leaks.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
67
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
68 6. Delegation.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
69
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
70 We finish at 5.15pm.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
71
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
72
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
73 Is this tutorial for me?
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
74 ------------------------
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
75
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
76 This tutorial aimed at Python web developers who already know a bit of
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
77 JavaScript, and who need to understand JavaScript better.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
78
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
79 The tutorial has two related objectives. One is a good understanding
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
80 of the counters example. The other is a good understanding of the
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
81 things that make JavaScript so different from Python (apart from
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
82 JavaScript being the only language supported by web browsers).
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
83
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
84 If you're thinking of taking this tutorial take the :doc:`gotcha-quiz`
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
85 and read through the :doc:`counters-example`. If you understand
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
86 what's there a bit, and would like to understand it more, then this
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
87 tutorial is for you.
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
88
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
89 Let me know
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
90 -----------
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
91
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
92 If you're going to attend the tutorial, I'd appreciate an email from
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
93 you that tells me a little bit about yourself and what you'd like to
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
94 get from the tutorial. If you have specific questions about
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
95 JavaScript, I'd like to here them also. (I can be contacted at
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
96 Jonathan.Fine1 at gmail.com.)
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
97
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
98 You can also, I believe, just turn up on the day, if there is
630e8132250e europython-2010-tutorial.rst: Drafted this page.
Jonathan Fine <jfine@pytex.org>
parents:
diff changeset
99 space. Don't forget to install the software on your laptop.