You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import { LightningElement, track, api } from 'lwc';
import createCase from '@salesforce/apex/CaseCreationController.createCase';
import uploadFile from '@salesforce/apex/CaseCreationController.uploadFile';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
I'm not quite sure what your asking with the detail provided, but to "glean" your request from the title, I think you asking about how to "stop" us from registering the unload event...
The SDK itself already handles (and has for years) for when an "unload" event (unload, beforeunload, visibilitychange and pagehide) is not supported by the active runtime
So when chrome just "stops" providing the "unload" event we will continue to work
If however, you want us to "stop" hooking one or more of the unload events we have a configuration where you can provide the "event" names that you don't want use to register
However, there is 1 catch. We NEED to hook at least 1 of these events to ensure that we can correctly handle the page unload scenario, so if you tell us to ignore several events and the active runtime doesn't support any of the remaining ones we will STILL turn around and hook all of the default one (effectively ignoring your requested config).
import { LightningElement, track, api } from 'lwc';
import createCase from '@salesforce/apex/CaseCreationController.createCase';
import uploadFile from '@salesforce/apex/CaseCreationController.uploadFile';
import { ShowToastEvent } from 'lightning/platformShowToastEvent';
export default class ParkEntryApplication extends LightningElement {
// Fields
companyToVisit = '';
contactPerson = '';
Email = '';
purposeOfEntry = '';
requestorFullName = '';
requestorCompanyName = '';
requestorEmail = '';
parkEntryDate;
duration = '';
peopleEntering = '';
vehiclePlateNumber = '';
uploadedFileUrl;
recordId;
fileData;
file;
base64;
filename;
}
The text was updated successfully, but these errors were encountered: