Thank you for reaching out to Microsoft Q&A forum
As states in Overview of SharePoint Framework Extensions and Build your first Form Customizer extension, the root cause of this behavior is Application Customizers can render only into the well‑known Top/Bottom page placeholders on modern pages, however, list forms sometimes render in reduced chrome (panel/dialog or full‑page minimal layout), or the experience may switch to classic or be overridden by Power Apps, in which cases those placeholders are not available, so tryCreateContent returns null and your React component never mounts.
In this context, you can follow below two approaches to see if it can resolve this behavior:
1/ Use SPFx Form Customizer for form pages
You can consider refactoring the customization to a Form Customizer and associate it with the affected list’s content types so it renders consistently on New/Edit/Display forms, independent of page placeholders. Deployment can be automated (PnP script) by setting the content‑type properties NewFormClientSideComponentId, EditFormClientSideComponentId, and DisplayFormClientSideComponentId.
Link reference: Build your first Form Customizer extension
2/ Harden the Application Customizer for page/route changes and missing placeholders.
In your onInit, listen to placeholderChangedEvent and application.navigatedEvent; on each callback, attempt tryCreateContent(Top|Bottom) and gracefully skip when null. This avoids stale mounts after SPA transitions and prevents errors when forms don’t expose placeholders.
// in Application Customizer
public async onInit(): Promise<void> {
this.context.placeholderProvider.placeholderChangedEvent.add(this, this.renderPlaceholders);
this.context.application.navigatedEvent.add(this, () => { this.disposePlaceholders(); this.renderPlaceholders(); });
}
private renderPlaceholders() {
const top = this.context.placeholderProvider.tryCreateContent(PlaceholderName.Top, { onDispose: this.onDispose });
if (top?.domElement) ReactDOM.render(<MyBanner/>, top.domElement);
For your information:
Note: Microsoft is providing this information as a convenience to you. These sites are not controlled by Microsoft, and Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please ensure that you fully understand the risks before using any suggestions from the above link.
Hope my answer will help you, for any further concern, kindly let me know in the comment section.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.