Skip to content

Latest commit

 

History

History
53 lines (34 loc) · 1.77 KB

README.md

File metadata and controls

53 lines (34 loc) · 1.77 KB

lighnting-out-heroku

A barebones Node.js app using Express 4.

This application is to demonstrate the Salesforce Lightning Out feature.

Checkout the Salesforce repo: SF Lightning Out

Pre-deployment steps

  1. Make sure you follow the Post Deployment steps from SF Lightning Out
  2. Use the Community URL you copied and replace the Community URL in: views/partials/header.ejs
  3. Replace the Community URL with you Community URL views/partials/lightning-out.ejs

Post-deployment steps

  1. Make sure you add the Heroku URL to SF CORS Setup -> CORS -> New
  2. Make sure you add the Heroku URL to SF CSP Trusted Sites Setup -> CSP Trusted Sites -> New Trusted Site

Running Locally

Make sure you have Node.js and the Heroku CLI installed.

$ git clone [email protected]:tiaanswart/lighnting-out-heroku.git # or clone your own fork
$ cd lighnting-out-heroku
$ npm install
$ npm start

Your app should now be running on localhost:5000.

Deploying to Heroku

$ heroku create
$ git push heroku master
$ heroku open

or

Deploy to Heroku

CORS

CORS must be enabled in Salesforce as well as the Node.js app, best to develop in Safari with CORS disabled

Documentation

For more information about Salesforce Lightning Out, see these articles: