Before the latest updates, we were able to use Javascript Post Messaging
from a VisualForce Home Page Component
in order to hide it when empty. For example:
if({!someCondition}) parent.postMessage('empty', '*' );
This strategy doesn't work any more, which leads me to believe that Post Messaging
is now broken from embedded VisualForce
. It doesn't seem like it should be affected by cross-domain issues for most browsers, but I wonder if that may be in play? I am using a version that lists support.
The solution we have dreamed up, but have not yet started to implement, is to write a batch/trigger that essentially checks {!someCondition}
and if it is false, we use the Metadata API to hide the Home Page Component
from the Home Page Layout
.
Is there still a way to conditionally hide a Home Page Component in real time?