【问题标题】:PNP PeoplePicker Type 'WebPartContext' is missing the following properties from type 'BaseComponentContext'PNP PeoplePicker 类型 \'WebPartContext\' 缺少来自类型 \'BaseComponentContext\' 的以下属性
【发布时间】:2022-09-28 17:18:24
【问题描述】:

我在我的 spfx react webpart 解决方案中使用 spfx Peoplepicker 控件,但 Peoplepicker 控件遇到以下错误。

错误 : 类型 \'WebPartContext\' 缺少类型 \'BaseComponentContext\' 中的以下属性:_isServedFromLocalhost、isServedFromLocalhostts(2739) IPeoplePicker.d.ts(14, 5):预期的类型来自属性 \'context\',它在类型 \'IntrinsicAttributes & IntrinsicClassAttributes<PeoplePicker> & Readonly<IPeoplePickerProps> & Readonly<...>\' 上声明

enter image description here

请发表评论并让我知道是否需要任何其他信息。

在解决方案中,我使用的是 spfx 1.11.0 版本并尝试了不同的 spfx 1.10.0 版本,但问题仍然相同。

  • 请在此处粘贴代码;也许做得更小以尽可能小地展示问题,并且不要使用图像。

标签: reactjs spfx peoplepicker pnp-js


【解决方案1】:

我遇到了同样的问题,我似乎无法在任何地方找到答案。 您是否设法解决了问题或找到了解决方案?

【讨论】:

猜你喜欢
  • 2022-11-11
  • 1970-01-01
  • 1970-01-01
  • 2021-04-20
  • 2021-07-29
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2019-09-11
相关资源
最近更新 更多