Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

56 lines (45 sloc) 1.533 kb
{% extends "base.html" %}
{% block title %}Tributary{% endblock %}
{% block style %}
<link rel='stylesheet' type='text/css' href='/static/css/embed.css' />
{% endblock %}
{% block gui %}
<div id='display'>
<svg id="tributarysvg"></svg>
</div>
{% endblock %}
{% block branding %}
<h1>Tributary</h1>
{% endblock %}
{% block scripts %}
<script src='/static/tributary.js'></script>
<script type="text/javascript">
//from the SO thread: http://stackoverflow.com/questions/950087/include-javascript-file-inside-javascript-file
//caching so we don't download every keystroke
var required_scripts = []
function script(src) {
if(_.include(required_scripts, src))
return true;
$.ajax({
url: src,
dataType: "script",
async: false, // this is the key
success: function () {
// all good...
//console.log("success")
required_scripts.push(src)
},
error: function () {
throw new Error("Could not load script " + src);
}
});
}
</script>
{% endblock %}
{% block jsinit %}
var model = new tributary.Tributary({"gist":"{{gist}}", "filename":"{{filename}}"})
tribView = new tributary.TributaryView({"model":model})
window.onresize = function(event) {
model.trigger("execute")
}
{% endblock %}
Jump to Line
Something went wrong with that request. Please try again.