precompile templates during build and add support for compileOptions