Skip to content
This repository has been archived by the owner on Oct 23, 2021. It is now read-only.

sp webpart base.baseclientsidewebpart.context

John Nguyen edited this page Apr 22, 2021 · 2 revisions

Home > @microsoft/sp-webpart-base > BaseClientSideWebPart > context

BaseClientSideWebPart.context property

Use the context object to access common services and state associated with the component.

Signature:

readonly context: WebPartContext;

Remarks

Child classes are expected to override this field by redeclaring it with a specialized type. It is meant to be a read-only property; the type cannot be declared as read-only in the base class (because it is initialized outside the constructor), but child classes should redeclare it as readonly.

Clone this wiki locally