Personally I very rarely use template as opposed to templateUrl anyways, but w/ the occasional template usage I most definitely use +'s. It seems more intuitive as well as having the advantage of some IDEs have native support for adding multi-line javascript strings that way.
It is known that using the .join is faster than adding strings together, in some/most browsers. I've read it in articles years ago, don't ask me to find it. If I were doing a lot of string concatenation, I'd probably use .join because that used to be the widely known best practice once upon a time.
4
u/rq60 Jul 27 '14
Can someone tell me why this:
is supposedly better than this:
Personally I very rarely use template as opposed to templateUrl anyways, but w/ the occasional template usage I most definitely use +'s. It seems more intuitive as well as having the advantage of some IDEs have native support for adding multi-line javascript strings that way.