A JavaServer Faces resource library is a collection of user-created components collected in a standard location in a web application. Resource libraries are identified according to a resource identifier, a string that represents a particular resource within a web application. Resources can be packaged either at the root of the web application or on the web application's classpath.
A resource packaged in the web application root must be in a subdirectory of a resources directory at the web application root.
A resource packaged in the web application classpath must be in a subdirectory of the META-INF/resources directory within a web application.
Resource identifiers are unique strings that conform to the following format:
Elements of the resource identifier in brackets () are optional. A resource name, identifying a particular resource (a file or a graphic, for example), is required. In firstcup, a resource library with the name components is packaged in the web application root, and this library contains one resource, a file called inputDate.xhtml. The resource identifier for this resource is therefore components/inputDate.xhtml, and it is located in the web application root at resources/components/inputDate.xhtml.