Mercurial > scratch
annotate pydershell/test.js @ 25:64fb84017d87
Added .hgignore.
author | Atul Varma <varmaa@toolness.com> |
---|---|
date | Mon, 07 Sep 2009 17:20:24 -0700 |
parents | 1950b0b5bcd8 |
children | b7037cd0f375 |
rev | line source |
---|---|
10 | 1 print('hello there dood'); |
2 | |
3 function blah() { | |
4 print('hi'); | |
5 try { | |
6 throw new Error('baffs'); | |
7 } catch (e) { | |
8 print('exception is ' + e); | |
9 throw e; | |
10 } | |
11 } | |
12 | |
17
1d62177c5c27
Added a safe js object wrapper.
Atul Varma <varmaa@toolness.com>
parents:
10
diff
changeset
|
13 //foo(blah); |
1d62177c5c27
Added a safe js object wrapper.
Atul Varma <varmaa@toolness.com>
parents:
10
diff
changeset
|
14 |
1d62177c5c27
Added a safe js object wrapper.
Atul Varma <varmaa@toolness.com>
parents:
10
diff
changeset
|
15 bar({blarg: "aweg", bar: function() { return this.blarg; }}); |
21
1950b0b5bcd8
It's now possible to expose python class instances to JS, if they're declared the right way (for security purposes).
Atul Varma <varmaa@toolness.com>
parents:
17
diff
changeset
|
16 |
1950b0b5bcd8
It's now possible to expose python class instances to JS, if they're declared the right way (for security purposes).
Atul Varma <varmaa@toolness.com>
parents:
17
diff
changeset
|
17 var mybaz = baz(); |
1950b0b5bcd8
It's now possible to expose python class instances to JS, if they're declared the right way (for security purposes).
Atul Varma <varmaa@toolness.com>
parents:
17
diff
changeset
|
18 print(mybaz.woozle(5)); |
1950b0b5bcd8
It's now possible to expose python class instances to JS, if they're declared the right way (for security purposes).
Atul Varma <varmaa@toolness.com>
parents:
17
diff
changeset
|
19 ensureBaz(mybaz); |