moving ng templating code into a new lib folder