Skip to content

Instantly share code, notes, and snippets.

IPython Shell

How to install: pip install ipython

  • Tab Completion
In [1]: x = 3+4j

In [2]: x.<Tab>
var http = require('http');
http.createServer(
function (req, res) {
var body = [];
req.on('error', function(err) {
console.error('error', err);
}).on('data', function(chunk) {
body.push(chunk);
}).on('end', function() {
@djedi
djedi / app.html
Last active March 31, 2017 14:41 — forked from Vheissu/app.html
Example of a HTML only partial for the book -- Aurelia For Real World Web Applications available here: https://leanpub.com/aurelia-for-real-world-applications/
<template>
<require from="./my-element.html"></require>
<my-element heading="This is the heading" body-text="This is the bodyText"></my-element>
</template>
@djedi
djedi / app.html
Created March 31, 2017 14:49
Basic Aurelia Gist Starter
<template>
</template>
@djedi
djedi / app.html
Last active March 31, 2017 14:58
Aurelia Replaceable Parts
<template>
<require from="./comp.html"></require>
<comp></comp>
<comp>
<template replace-part="repl">
This part is being replaced.
</template>
</comp>
<comp>
<template replace-part="repl">
@djedi
djedi / app.html
Last active April 4, 2017 12:57
Aurelia Replaceable Parts
<template>
<require from="./comp.html"></require>
<comp></comp>
<comp>
<template replace-part="repl">
I've been replaced.
</template>
</comp>
<comp>
<template replace-part="repl">
@djedi
djedi / app.html
Created April 4, 2017 23:02
Array of object observer
<template>
<table>
<thead>
<tr>
<th>id</th>
<th>Title</th>
<th>Updated</th>
<th>Status</th>
</tr>
</thead>
@djedi
djedi / app.html
Last active April 4, 2017 23:04
Array of object observer
<template>
<table>
<thead>
<tr>
<th>id</th>
<th>Title</th>
<th>Updated</th>
<th>Status</th>
</tr>
</thead>
@djedi
djedi / app.html
Created April 6, 2017 16:43
Basic Aurelia Gist Starter
<template>
</template>
@djedi
djedi / app.html
Last active April 6, 2017 17:05
collection observer
<template>
<button click.delegate="addData()">Add Data</button>
<hr>
Data:
<table>
<tr repeat.for="val of data">
<td>${val}</td>
</tr>
</table>