Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
76 lines (55 sloc) 2.53 KB
<!doctype html>
body {
max-width: 900px;
margin: 40px auto;
/*font-family: sans-serif;*/
<!--load nb.js script-->
<script src=''></script>
<!-- <script src="./nb.js"></script> -->
<link rel="stylesheet" href="">
<script src=""></script>
<script src=""></script>
<p>Give the converter a try below. Just input the url for the raw content for one of your notebooks and click render to see the results. This <a href="">example</a> uses a few of the custom settings, including <a href="">highlightjs</a> and <a href="">showdownjs</a>.</p>
<input id="url" type="text" size="70" value=""/>
<input id="click" type="button" value="Render" onclick="renderNotebook();"/>
<div id="notebook">
<!--Inserts Notebook HTML here-->
var converter = new showdown.Converter();
var settings = {
'code': true, //Include code cells
'markdown': true, //Include markdown cells
'tables': true, //Include html data tables
'images': true, //Include .png outputs
'headline': true, //Include the first <h*> headline, removing useful if page has title already
'tableoutline': true, //Includes the black table outline
'codehighlighter': 'highlightjs', //Code highlighting. Options: 'none', 'highlightjs', 'prettyprint'
'mdconverter': converter //Use included simple markdown converter. Options: 'default', showdown object
function renderNotebook() {
function callback(html) {
//Replace html rater than inserting at end
//so people can try multiple notebooks
var el = document.getElementById('notebook');
el.innerHTML = html;
//Reset so it can be called again if new
//notebook url is entered:
hljs.initHighlighting.called = false;
var url = document.getElementById('url').value;
nb.returnNotebook(url, callback, settings);