This means that you’re using plain HTML <head>
instead of JSF <h:head>
in your XHTML template. The JSF <h:head>
allows automatic inclusion of CSS/JS resources in the generated HTML <head>
via @ResourceDependency
annotations. PrimeFaces as being a jQuery based JSF component library needs to auto-include some jQuery/UI JS/CSS files and this really requires a <h:head>
.
So, search for a
<head>
<title>Some title</title>
...
</head>
in your templates and replace it by
<h:head>
<title>Some title</title>
...
</h:head>
See also:
- What’s the difference between <h:head> and <head> in Java Facelets?
- Unable to understand <h:head> behaviour
- How to programmatically add JS and CSS resources to <h:head>?
- How to include another XHTML in XHTML using JSF 2.0 Facelets?