ZouBi
ZouBi

Reputation: 813

Richfaces vs Primefaces : Cannot read property 'requests' of undefined

I'm developping a web application in JSF that uses Richfaces 4.3.0 CRI and Primefaces 3.4.2. I've just notified that on any page that uses Primefaces components, I can see in the Javascript console this error happened:

Uncaught TypeError: Cannot read property 'requests' of undefined packed.js:3243

But the packed.js file is the one included in the Richfaces library package. But on each page that doesn't use a Primefaces component, this error doesn't occur.

Problem is sometimes, this error makes stop working some others Javascript code (other functions are aborted).

I wonder if it exists a way to fix it or a work around? I just want to avoid that other scripts become aborted because of this error.

Upvotes: 1

Views: 1514

Answers (1)

ZouBi
ZouBi

Reputation: 813

Finally, and obviously, it was a problem of compatibility because Richfaces and Primefaces don't use the same version of jquery.js. But thanks to this article: Working towards RichFaces(4.2.2-Fianl) / PrimeFaces(3.3) compatibility, I solved the problem. But it seems to work only for the version of RichFaces and Primefaces used in the article. Not with the most recent versions.

Upvotes: 1

Related Questions