Loading

Salesforce Lightning Web Components: Unsupported Imports from the 'lwc' Module Will Be Restricted in Future Releases

Veröffentlichungsdatum: Oct 12, 2026
Beschreibung

Salesforce identified that some Lightning Web Components (LWC) are using unsupported imports from the 'lwc' module. While some of these imports historically worked due to accidental platform behavior, they are not officially supported for deployed platform components.

Lösung

This article explains which imports from the "lwc" module are officially supported in Salesforce Lightning Web Components, and what to do if your components use imports that may be restricted in future releases.

Supported vs. Unsupported Imports

The only officially supported imports from 'lwc' for deployed platform components are LightningElement, api, track, wire, and unwrap, as shown in this statement:

import { LightningElement, api, track, wire, unwrap } from 'lwc';

Any other imports from 'lwc' should be considered unsupported and may be restricted in future releases. For example, importing createElement from 'lwc' is an unsupported usage, as shown in this statement:

import { createElement } from 'lwc';

Recommended Actions

Customers are strongly encouraged to review and update their Lightning Web Components to ensure they only use officially supported imports from "lwc". Recommended actions include:

  • Remove unsupported imports from components.
  • Refactor components to align with supported LWC APIs.
  • Avoid relying on undocumented or accidental platform behavior.

Although some unsupported imports are temporarily permitted, this should not be treated as long-term supported behavior.

Nummer des Knowledge-Artikels

005385014

 
Laden
Salesforce Help | Article