Fix JS scripts paths
Change templates from type text/html to text/template