Chapter 5. Development Best Practices
In the previous chapters, we learned about various configuration best practices including caching best practices. Liferay Portal is a portal platform, and portal solutions are developed on top of it. Hence, it is very important to follow best practices during the development of custom features to build high performing portal solutions. In this chapter, we will focus on Liferay-Portal-specific development best practices. By the end of this chapter, we will learn the following topics:
UI best practices
Reducing the number of JavaScript files
Reducing the number of CSS files
Using CSS image sprites
Minifying JavaScript files
JavaScript tag positioning
Analyzing web page performance using tools
Java development best practices
Use of dynamic query and custom queries
Use of the Cache API to cache resources
Coding best practices