mirror of https://github.com/mindoc-org/mindoc.git
32 lines
620 B
JavaScript
32 lines
620 B
JavaScript
/*
|
|
Language: Mojolicious
|
|
Requires: xml.js, perl.js
|
|
Author: Dotan Dimet <dotan@corky.net>
|
|
Description: Mojolicious .ep (Embedded Perl) templates
|
|
Category: template
|
|
*/
|
|
function(hljs) {
|
|
return {
|
|
subLanguage: 'xml',
|
|
contains: [
|
|
{
|
|
className: 'meta',
|
|
begin: '^__(END|DATA)__$'
|
|
},
|
|
// mojolicious line
|
|
{
|
|
begin: "^\\s*%{1,2}={0,2}", end: '$',
|
|
subLanguage: 'perl'
|
|
},
|
|
// mojolicious block
|
|
{
|
|
begin: "<%{1,2}={0,2}",
|
|
end: "={0,1}%>",
|
|
subLanguage: 'perl',
|
|
excludeBegin: true,
|
|
excludeEnd: true
|
|
}
|
|
]
|
|
};
|
|
}
|