Using the Liferay UI Taglib

The Liferay UI tag library provides tags that implement commonly used UI components. These tags make your markup consistent, responsive, and accessible.

You can find a list of the available Liferay UI taglibs in the Liferay UI taglibdocs. Each taglib has a list of attributes that can be passed to the tag. Some of these are required and some are optional. See the taglibdocs to view the requirements for each tag. You’ll find the full markup generated by the tags in their JSPs in their Liferay Github Repo folders.

To use the Liferay-UI taglib library in your apps, you must add the following declaration to your JSP:

<%@ taglib prefix="liferay-ui" uri="" %>

The Liferay-UI taglib is also available via a macro for your FreeMarker theme and web content templates. Follow this syntax:

<@liferay_ui["tag-name"] attribute="string value" attribute=10 />

This section of tutorials covers how to create UI components with the Liferay UI taglibs. Each tutorial contains code examples along with a screenshot of the resulting UI.

« Introduction to Front-End TaglibsLiferay UI Icons »
Was this article helpful?
0 out of 0 found this helpful