this.context.pageContext.site.id undefined in classic pages only
Category
[ X] Bug
Expected or Desired Behavior
Using the Reactjs template: this.context.pageContext.site.id is defined when testing against in a modern page using workbench.aspx but is undefined in a classic page.
Observed Behavior
this.context.pageContext.site.id should not be undefined in classic pages
Steps to Reproduce
Create a React web part that prints the value of this.context.pageContext.site.id to the console. Check that it works when the web part is hosted workbench.aspx. Bundle it as app to ship. Add the web part to a classic page. See that the property is null.
Thanks Paul - you are absolutely correct.
This is a known issue and should be fixed soon.
The issue was resolved with server side changes. It will take about two to three weeks before you will see the effect of the changes.
Hi @paulryan, please let us know if this is still and issue.
Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: Issue List: Our approach to locked issues