Look Up Distortion Details in LWS Distortion Viewer

LWS applies distortions to code running in a JavaScript sandbox to help prevent behavior that’s not secure. LWS Distortion Viewer describes the distortion by explaining the vulnerability of the affected API, and the distorted behavior that mitigates the vulnerability. This tool can help you learn how to modify your JavaScript code to avoid distortions that affect your components.

LWS Distortion Viewer shows the JavaScript APIs that are blocked or modified by Lightning Web Security. If an API isn't listed here, LWS allows the API's native behavior. For more information about distortions, see How Lightning Web Security Works.

LWS Distortion Viewer is available from the Component Library navigation bar.

Here’s a direct link to the tool: https://developer.salesforce.com/docs/component-library/tools/lws-distortion-viewer.

LWS Distortion Viewer with open document

LWS Distortion Viewer lists the distortions for JavaScript APIs alphabetically by object name, along with a number that indicates the number of APIs that are distorted for the object. Click an object in the left panel, then click an API in the right panel to view information about the API distortion.

For information about solving some issues with your code after LWS distortions are applied, see Troubleshoot in Lightning Web Security.