• Azhar Beebeejaun
  • 5 Points
  • Member since 2016

  • Chatter
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
  • 4
I noticed that my Lightning Out App in classic SF is no longer working and the console shows a parsing error.
myVF:504 Uncaught SyntaxError: Unexpected token u in JSON at position 14660

I tried reverting to a version that worked from 3 weeks ago, but it seems to still not work..
Here is my VF code.
<apex:page sidebar="false">
<apex:includeLightning />
    <div id="myDivId">
        var myUserContext = "{!$User.UITheme}";
        $Lightning.use("c:LEXComp", function() {
            function(cmp) {
                console.log('component created');

The lightning component works fine separately and within the LEX environment, this seems to only be an issue with Lightning Out.
I have a lightning component which invokes a third party popup window as a lightbox. The window is served from another domain.
I would like for when that thrid party window closes to call a JavaScript method in my Lightning component to receive some data. 

The best way I found to pass the results is via window.postMessage because the thirda party window and the lightning components are from different domains. 
The quiestion I have is how to receid that postMessage even from my Lightning component. 

I tried adding the below method to my Lighting component's controller but it did not work: 
 doInit : function(component, event, helper) {
        var listener = function(event) {
           //Do work here
        if (addEventListener){
              addEventListener("message", listener, false);
        } else {
              attachEvent("onmessage", listener);

Could you please help me figure this out.

My Salesforce environment is configured for Salesforce single sign-on, and I would like to render a Visualforce page within an existing application web page, external to Salesforce.


By adusting the clickjack protection settings, I can render a Visualforce page in an iframe on a page external to Salesforce, but only if the browser has already authenticated to Salesforce.  But if the user has not yet authenticated to Salesforce, the iframe render stops once it reaches login.salesforce.com because x-frame-options: deny tells the browser that the page may not be rendered in an iframe.  Specifically, login.salesforce.com returns x-frame-options:deny on the final call to login.salesforce.com, if you're familiar with the sequence of redirects used for SSO.  I can post a trace if that would help explain better.


It would be high value to be able to render visual force pages, and the associated single sign-on authentication, as an iframe.


Is this possible using a configuration setting or is there another workaround possible?  Is there any possibility that this may change in a future release?