0

I've created a bottom placeholder with spfx and react and it contains a menu. when I select an option from the dropdown menu the page refresh but the bottom placeholder still showing the dropdown oppened, i like everything refreshes but not the bottom placeholder. Does the placeholder a refresh when a new page loads?

regards

Americo Perez
  • 95
  • 1
  • 4
  • 17

1 Answers1

1

Yes, on page load all the elements in the page will be reloaded. In OnInit method, call the render placeholders method like this.

this.context.placeholderProvider.changedEvent.add(this, this._renderPlaceHolders);

https://learn.microsoft.com/en-us/sharepoint/dev/spfx/extensions/get-started/using-page-placeholder-with-extensions

Naveen Prasath
  • 539
  • 1
  • 3
  • 23