-
-
Save arunoda/111580cca51301418487 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
<head> | |
<title>abc</title> | |
</head> | |
<body> | |
{{#sourceCode}} | |
<template name="books"> | |
<input type="text" placeholder="Search..." value="{{booksSearchQuery}}"> | |
{{#if searchResults.count}} | |
<ul> | |
{{#each searchResults}} | |
<li>{{name}}</li> | |
{{/each}} | |
</ul> | |
{{/if}} | |
</template> | |
<script type="text/javascript"> | |
UI.AA(); | |
</script> | |
{{/sourceCode}} | |
</body> | |
<template name="sourceCode"> | |
<pre><code data-language="html"> | |
{{#with UI.contentBlock}} | |
{{getCode}} | |
{{/with}} | |
</code></pre> | |
</template> |
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
if (Meteor.isClient) { | |
Template.sourceCode.getCode = function() { | |
var htmlString = UI.toHTML(this.extend({data: function (data) { return data; }})); | |
return htmlString; | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment