ipython/ipython — pull request #5130 by mberth (2014-02-15 15:15:20+00:00)
Title: Coffeescript notebook

I want to use CoffeeScript in place of Python inside an IPython notebook, so I can work in the interactive and explorative way that I like so much about IPython. Please give me feedback on the changes / extensions below. I'm new to IPython development, perhaps there are better ways to package this. Furthermore there is no testing at the moment. Any comments and criticisms are very much welcome. -- Matthias

CoffeeScript Cell Magic
-----------------------

Execute CoffeeScript in the browser. Experience is similar to running python in the notebook:
results are shown in the notebook, variables can be accessed across cells etc.

Example:

%%coffee
console.log "Hello from CoffeeScript!"

Together with

%default_cell_magic coffee

(see below) this can be used to write CoffeeScript notebooks with code being executed in the context of the browser.

Screenshots
----------------

![coffeescript_notebook](https://f.cloud.github.com/assets/77945/2178024/4c49d968-9652-11e3-89a5-17b1a27dcc0b.png)

![coffeescript_notebook_2](https://f.cloud.github.com/assets/77945/2178029/bff0c78c-9652-11e3-8a23-6e1b4fb09746.png)

Default Cell Magic
------------------

Use

%default_cell_magic xyz

to have the `%%xyz` cell magic prepended automatically to all subsequent input cells. See

%default_cell_magic?

for details.