This project is part of a technical proof of concept of a Progressive Web App (PWA) made with the Lightning Web Component Open Source (LWC OSS) framework. Its purpose is to:
- Test the LWC OSS framework as a Progressive Web App, a web application that can be installed on desktop computers and mobile devices like Apple/Google store applications.
- Get and update data from the Salesforce platform in a secure way (JWT authentication).
- Emit web push notifications from the Salesforce platform when a data has been updated.
- Use the Lightning base components and the SLDS stylesheet on front end.
This repository contains the Salesforce development of the application (back-end). When the Likes______c field increments on a Record______c, an Apex trigger sends a callout to the Web Push Generator webservice in order to send a web push notification to users who subscribed in the front-end application.
The Salesforce application can be installed as an unlocked package:
- Follow this link for Sandboxes
- Follow this link for Production environments, Developer Editions and Trailhead Playgrounds
But you still have to configure the named credentials and the connected app manually.
Three applications interacts with each others to run the Record Shop:
- Record Shop (Heroku): front-end application, hosted on Heroku.
- Record Shop (Salesforce): back-end application, hosts the data about records and triggers the notifications emission using the web-push-generator.
- Web Push Generator: Node.js utility application using the web-push npm package to send notifications to subscribed users.