When we developing simple JS app / website we don't even need to test something. If everything is simple - there is no reason to make it hard.
The are a lot of ways to test different cases:
- console.time() method of testing some code part performance;
console.time('timerName'); /* your code */ console.timeEnd('timerName');
Tones of developers fighting with unneeded kilobytes of data on their web projects to increase their performance. Minimization of pages weight, reducing the number of requests, place of including scripts and many other things affect the speed of loading and displaying the pages. Developers using css3 sprites to reduce the number of queries when page loads. Base64 image encoding also using in this context and in some way it is more convenient.
... Read more to know the benefits and drawbacks