在本地运行 React 自定义小部件 Azure API 管理开发人员门户时出错

问题描述 投票:0回答:1

我正在尝试使用 React 模板在 Azure API 管理开发人员门户中创建自定义小部件。我无法在本地运行自定义小部件并面临以下错误。

错误:utils.ts:57 无法从 URL 的搜索参数中获取“editorData”: http://localhost:3000/?editorData= SyntaxError: JSON 输入意外结束

代码在 Microsoft 库中失败。

我已关注 Microsoft 的这篇文章,但它并没有帮助解决问题。

https://learn.microsoft.com/en-us/azure/api-management/developer-portal-extend-custom-functionity#create-and-upload-custom-widget

azure azure-api-management
1个回答
0
投票

从“main.tsx”中删除元素,它将解锁您。 它应该看起来像这样:

<StrictMode>
  <WidgetDataProvider>
    <App />
  </WidgetDataProvider>
</StrictMode>
最新问题
© www.soinside.com 2019 - 2024. All rights reserved.