Skip to content

Instantly share code, notes, and snippets.

@nagataka
Last active December 23, 2015 16:59
Show Gist options
  • Save nagataka/6666196 to your computer and use it in GitHub Desktop.
Save nagataka/6666196 to your computer and use it in GitHub Desktop.
template for using processing.js
<!DOCTYPE html>
<html>
<head>
<title>HERE IS TITLE</title>
<script type="text/javascript" src="processing.js"></script>
<script type="text/javascript">
window.onload = function(){
//var canvas = document.getElementById('canvas1');
//var codeElm = document.getElementById('processing-code');
//var code = codeElm.textContent || codeElm.innerText;
//new Processing(canvas,code);
};
</script>
<script id="processing-code" type="application/processing">
//write processing code here
</script>
</head>
<body>
<h1>Processing Template</h1>
<div>
<canvas id="canvas1" width="400" height="400"></canvas>
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment