Created
September 7, 2010 05:25
-
-
Save qoelet/567905 to your computer and use it in GitHub Desktop.
This file contains hidden or 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> | |
<head> | |
<title>Dojo - Namespaces!</title> | |
<link href="dojo1.5/dojo/resources/dojo.css"> | |
<script src="dojo1.5/dojo/dojo.js" type="text/javascript"></script> | |
</head> | |
<body> | |
<div id="hello">Hello Dojo!</div> | |
<script type="text/javascript"> | |
dojo.registerModulePath("kenny", "/kenny"); | |
dojo.require("kenny.calculator"); | |
// req for async loading | |
dojo.addOnLoad(function() { | |
dojo.body().innerHTML = "so 2 + 2 = " + kenny.calculator.sum(2,2); | |
}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment