Conviently place all templates into special directory and compile onсe. Now I writed own functions, for example so:
make_templates(Dir)->
Files = filelib:wildcard(Dir++"/*.dtl"),
compile(Files,0).
compile([],_)->ok;
compile([File|T],N)->
io:format("Compile file ~p~n",[File]),
R=erlydtl:compile_file(
File,
"template_"++integer_to_list(N),
[{out_dir},"templates"]),
compile(T,N+1).
Is exist standard way for do this with erlydtl?