passing local var while rendering templates