Modules Support
-
— Supported. Expected to behave as documented.
-
— Limited Support. Can be used, but has known (and possibly unknown) issues.
-
— Not Supported. Doesn’t work, or shouldn’t be used.
Module | Status | Comments |
---|---|---|
lightning
Namespace Modules These modules contain resources that don’t change and are universal to all orgs. |
||
lightning/alert Create an alert modal within your component. |
![]() |
|
lightning/confirm Create a confirm modal within your component. |
![]() |
|
lightning/empApi Provides methods for subscribing to a streaming channel and listening to event messages. |
![]() |
Not supported in mobile apps. |
lightning/flowSupport Provides events to control flow navigation and notify the flow of changes in attribute values. |
![]() |
|
lightning/messageService Communicates across the DOM between Visualforce pages, Aura components, and Lightning web components. |
![]() |
Lightning Aura components and Visualforce aren’t supported in the Field Service mobile app. This isn’t expected to change. |
lightning/navigation Generates a URL or navigates to a page reference. |
![]() |
Available for use, but supported page reference types are limited. See Navigation for details. |
lightning/pageReferenceUtils Provides utilities for encoding and decoding default field values. |
![]() |
Not supported in mobile apps. |
lightning/platformResourceLoader Imports a third-party JavaScript or CSS library. |
![]() |
Not supported for offline use. |
lightning/platformShowToastEvent Displays toasts to provide feedback to a user following an action, such as after a record is created. |
![]() |
You can import this module and fire toast events. However, toast messages aren’t handled or displayed. Use lightning/alert, lightning/confirm, or lightning/prompt instead. |
lightning/prompt Create a prompt modal within your component. |
![]() |
|
lightning/userConsentCookie Utility functions to incorporate the Cookie Consent mechanism in your components. |
![]() |
Relevant only for Experience Builder pages. |
@salesforce
Scoped Modules The shape of these modules can be dynamic, defined by your organization’s metadata. |
||
@salesforce/apex Import Apex methods as functions that a component can call either via @wire or imperatively. |
![]() |
See Use Apex While Mobile and Offline for usage details. |
@salesforce/apexContinuation Import methods from Apex continuation classes. |
![]() |
See Use Apex While Mobile and Offline for usage details. |
@salesforce/client/formFactor Import a name that refers to the form factor of the hardware running the app. |
![]() |
This module “works,” but always returns Small when used in an LWC Offline-enabled app. |
@salesforce/community Import the ID of the current Experience Builder site. |
![]() |
Relevant only for Experience Builder pages. |
@salesforce/contentAssetUrl Import content asset files. |
![]() |
|
@salesforce/i18n Import internationalization properties. |
![]() |
|
@salesforce/label Import labels defined in your Salesforce organization. |
![]() |
|
@salesforce/messageChannel Import a Lightning message channel that a component can use to communicate via the Lightning Message Service. |
![]() |
Lightning Message Service isn’t supported in LWC Offline-enabled mobile apps. |
@salesforce/resourceUrl Import static resources defined in your Salesforce organization. |
![]() |
|
@salesforce/schema Import references to Salesforce objects and fields defined in your org. |
![]() |
|
@salesforce/user Import the current user’s ID. |
![]() |
|
@salesforce/userPermission Import a permission and check whether it’s assigned to the current user. |
![]() |
|
@salesforce/customPermission Import a custom permission and check whether it’s assigned to the current user. |
![]() |