summaryrefslogtreecommitdiff
path: root/lib/VN3/Docs/JS.pm
blob: 397842fd7f9c43fe18824df795cc1ab4f8f1e074 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
package Docs::JS;

use VN3::Prelude;
use VN3::Docs::Lib;

my $elm_Content = elm_api Content => {};

json_api '/js/markdown.json', {
    content => { required => 0, default => '' }
}, sub {
    return $elm_Unauth->() if !auth->permDbmod;
    $elm_Content->(md2html shift->{content});
};

1;