libs/page_rendering/page_renderer.js
Function render_file_by_context
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
page_renderer.prototype.render_file_by_context = function (template_path, context, culture) {
// extracts the relative path to the template from the absolute path
const file_regex_match = template_path.match(/pages(?:\/|\\)(.*)\.([^\\/]+)$/)
const filename = file_regex_match[1]