[ 
https://issues.apache.org/jira/browse/MYFACES-4700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17906540#comment-17906540
 ] 

Werner Punz commented on MYFACES-4700:
--------------------------------------

The old code was using console or if no console was available alert, I 
basically removed the alerts for several reason in the new code:

a) The old code had to handle browsers which could not provide console logging

b) No browser which still is in use widely which the new codebase covers does 
not have console

c) Alerts are blocking and intrusive but if you want them you can re-add them 
via a listener

I personally think Mojarra still uses alerts because the codebase is old!

I don´t think the spec states clearly you have to use alerts. We can re-add 
them if you guys want it. I am just not a big fan of them!

 

> Javascript AJAX: displayError only when no faces.ajax.addOnError listener was 
> registred
> ---------------------------------------------------------------------------------------
>
>                 Key: MYFACES-4700
>                 URL: https://issues.apache.org/jira/browse/MYFACES-4700
>             Project: MyFaces Core
>          Issue Type: Improvement
>            Reporter: Thomas Andraschko
>            Assignee: Werner Punz
>            Priority: Major
>             Fix For: 5.0.0, 4.0.3, 4.1.1
>
>
> Currently writing some docs for PF exception handling and there is one 
> difference in Mojarra and MyFaces:
> In Mojarra, the error is only shown via alert, when no listener was registred 
> and its ProjectStage Development: 
> https://github.com/eclipse-ee4j/mojarra/blob/master/impl/src/main/resources/META-INF/resources/jakarta.faces/faces-uncompressed.js#L1442
> In MyFaces, we always use console (or alert if configured) to log the error, 
> also if listeners are defined.
> I think we should at least only use console or alert, if no global listener 
> is defined. Or only in ProjectStage Development? WDYT [~werpu]?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to