Skip to main content
Is it possible to use lightning components in Force.com Site with Visualforce page? I can't find a definitive answer.  Below is my code:

 

​<aura:application access="GLOBAL" extends="ltng:outApp" implements="ltng:allowGuestAccess">

<aura:dependency resource="c:sameplecomponent"/>

</aura:application>

<script src="https://yourCommunityDomain/communityURL/lightning/lightning.out.js"></script>

<script>

$Lightning.use("c:CF_CustomerContactFormApp", function() {

$Lightning.createComponent("c:sameplecomponent",

"",

"lightning",

function(cmp) {

// do some stuff

});

},

"https://yourCommunityDomain/communityURL"

);

Is it also possible to do this without community? 

 
3 respostas
  1. 3 de abr. de 2018, 21:52
    I think my code looks the same as some of the answers in the thread. But I get a 500 error when I don't include the community url link, and a 404 error when I do.
0/9000