Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function renderPugFileAsHtml(file: string) : string {
const templateName = 'flutter'
const parsed: Block = pugload.file(file, {
lex: puglex,
parse: pugparse,
basedir: dir
})
const linked: Block = puglinker(parsed)
addPugLineAttributes(linked)
const codegenfn = pugcodegen(linked, {
compileDebug: false,
pretty: true,
inlineRuntimeFunctions: false,
templateName
});
const pugTemplate = pugwrap(codegenfn, templateName);
return pugTemplate()
}