Created
August 31, 2012 05:58
-
-
Save nathanathan/3549496 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"category": "help", | |
"components": [ | |
"want", "delimiters", | |
"create synonyms", "delimiters", | |
{"terminal": "a language node"}, | |
{"regex": ".*"} | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
<title>Widget</title> | |
<style> | |
</style> | |
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js" type="text/javascript"></script> | |
<script> | |
$(document).ready(function(){ | |
$('.example').hide(); | |
$('.showExample').click(function(evt){ | |
$(this).hide(); | |
$('.example').show(); | |
}); | |
}); | |
</script> | |
</head> | |
<body> | |
<p>You can add language nodes by submiting gists that describe them.</p> | |
<p>Language nodes require the following components.</p> | |
<ol> | |
<li>A category name. (You can think of a category as a non-terminal node in a CFG.)</li> | |
<li>An ordered list of component categories and/or terminals to parse queries with.</li> | |
<li>A document or function for creating the node's UI element.</li> | |
</ol> | |
<center> | |
<form action="submitGist.html"> | |
<label>Enter a gist url:</label> | |
<input style="width:40em"></input> | |
<button>submit</button> | |
</form> | |
<button class="showExample">Show example gist</button> | |
</center> | |
<div class="example"> | |
<script src="https://gist.github.com/3549496.js"></script> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment