I would like to design a webpage using JSF.
Some parts of the page I can layout using <h:panelGroup>
and <h:panelGrid>
or, instead, I can use <p>
, <div>
, etc instead.
Just wondering which is preferable for best practices.
Thanks!
If you don't need the features provided by the JSF tag, I'd prefer to use plain HTML.
For example, <h:panelGroup>
has a rendered
attribute that allows you bind to a backing bean boolean variable to conditionally display the output, but with a <div>
or <span>
, you cannot do this.
The <h:panelGroup>
will by default generate a <span>
. If you prefer a <div>
, then you can use <h:panelGroup layout="block">
. It will generate a <div>
for you .
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With