CombinedResourceHandler: Myfaces ParseError in Dev Mode
See original GitHub issueDescribe the bug @tandraschko I have attached this reproducer: pfe-combinedresourcehandler.zip
To get the issue run the reproducer mvn clean jetty:run -Pmyfaces23
with JSF mode Development and press the “Update” button twice. On the second press you will see this in the console for the AJAX response.
Now run the reproducer again in JSF mode Production mvn clean jetty:run -Pmyfaces23
and there is no errors or problems. I think it stems from MyFaces having an issue with duplicate ID’s for this piece of code in our handler:
https://github.com/primefaces-extensions/primefaces-extensions/blob/fd939e77a2e26c765bd06efa5692fde8e3fba4b2/core/src/main/java/org/primefaces/extensions/application/PrimeFacesScriptProcessor.java#L169-L175
I used to have ID’s on there but had to be removed because of this ticket: https://github.com/primefaces-extensions/primefaces-extensions/issues/486
Any thoughts you have on this would be appreciated. It works fine in Mojarra in Development mode but I am wondering which library is doing the right thing?
Issue Analytics
- State:
- Created 2 years ago
- Comments:10 (10 by maintainers)
OK @tandraschko here is what I have discovered in my research and settled on because I don’t know exactly what is wrong in MyFaces or MAY NOT BE WRONG it could be wrong in Mojarra who knows. But…
UIViewRoot.addComponentResource
as reported in this ticket: https://github.com/primefaces-extensions/primefaces-extensions/issues/486The solution I settled on was to set an ID for MyFaces and leave it blank for Mojarra. I have tested and this now works for all 4 use cases MyFaces and Mojarra and Development mode and Production Mode.
cc @Phipsee since you reported the issues with Mojarra I wanted you to see this ticket.
Before when I was manually setting an ID both Mojarra and Myfaces turn it into a SPAN like…
So I had to remove the ID’s from this to let it generate the script properly without the SPAN