ProcessWire icon indicating copy to clipboard operation
ProcessWire copied to clipboard

FileCompiler: Allow compilation of non-php Files

Open felixwahner opened this issue 8 years ago • 4 comments

The new FileCompiler is a great addition for those who don't like/want to use plain PHP as a templating language. We've just recently started developing a new FileCompiler module ( FileCompilerTwig ) which is going to replace "TemplateTwigReplace". As far as we've noticed currently only files ending with .php are going to be compiled. Could you think about re-enabling the $config->templateExtension setting? This would be a great addition for those who are about to write other FileCompilers that won't use .php Files.

felixwahner avatar Jun 21 '16 07:06 felixwahner

I think I can add this, and that .php file limitation there is a mistake, as it was supposed to include .inc and .module as well. Which extension(s) did you want to support?

ryancramerdesign avatar Jun 28 '16 14:06 ryancramerdesign

That's great! I think adding .tpl, .latte and .twig would cover all bigger php templating engines.

felixwahner avatar Jul 01 '16 15:07 felixwahner

Having this as a config option would be great - there are, and will be, more template engines.

netcarver avatar Jul 01 '16 20:07 netcarver

Ok. That would be even better!

felixwahner avatar Jul 02 '16 08:07 felixwahner