Make template compilation more synchronus