mirror of
https://github.com/jsdoc/jsdoc.git
synced 2025-12-08 19:46:11 +00:00
28 lines
639 B
JavaScript
28 lines
639 B
JavaScript
(function() {
|
|
|
|
include('templates/lib/janl/mustache.js');
|
|
|
|
publish = function(docs, opts) {
|
|
var out = '',
|
|
template = readFile(BASEDIR + 'templates/default/tmpl/index.html');
|
|
|
|
var summarize = function () {
|
|
return function(text, render) {
|
|
text = render(text);
|
|
/^(.*?(\.|\n|\r|$))/.test(text);
|
|
return RegExp.$1;
|
|
}
|
|
};
|
|
|
|
out = Mustache.to_html(
|
|
template,
|
|
{
|
|
docs: docs,
|
|
summarize: summarize
|
|
}
|
|
);
|
|
|
|
print(out);
|
|
}
|
|
|
|
})(); |