SharePoint Online,Framework 1.1和Edge - 无法使用Workbench [英] SharePoint Online, Framework 1.1 and Edge - Can't Use Workbench

查看:91
本文介绍了SharePoint Online,Framework 1.1和Edge - 无法使用Workbench的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚开始使用SharePoint Framework 1.1开发客户端Web部件。  Edge是我的默认浏览器。




我在O365 SharePoint租户上设置了开发者网站。 它是使用  Developer
Site
template。




当我跑步时 gulp
serve
,VS Code启动Edge以访问localhost上的工作台,以及everyt兴按预期工作。   但是
如果我尝试使用Edge在O365租户站点中加载工作台(同时  gulp
serve
仍然在运行)我收到以下通知:



您的
Web部件不会出现在工具箱中。请确保"gulp serve"正在Web部件项目中运行。请刷新页面一次"gulp serve"正在运行。




< p style =""> ...并且,正如通知所示,我的网页部件没有出现在工具箱中。:(




但是
当我在IE或Chrome中打开相同的在线网址时,我没有收到警告,我可以在工作台中查看我的网页部分没有任何问题。




是否有其他人遇到此问题并已解决? 如果是这样,你做了什么?




这是我的环境:






  • Windows 10 Pro,所有最新维护(包括Fall Creators'Update)

  • Visual S. tudio Code 1.19.3

  • @ microsoft / sp-build-web @ 1.1.0

  • @ microsoft / sp-core-library @ 1.1.0

  • @ microsoft / sp-lodash-subset @ 1.1.0

  • @ microsoft / sp-module-interfaces @ 1.1.1

  • @ microsoft / sp-office-ui-fabric-core @ 1.4.0

  • @ microsoft / sp-webpart-base @ 1.1.1

  • @ microsoft / sp-webpart-workbench @ 1.1.0

  • @ types / chai @ 3.5.2

  • @ types / mocha @ 2.2.47

  • @ types / webpack-env @ 1.13.5

  • ajv@5.2.5

  • gulp@3.9.1



仅供参考,我已经运行了  gulp
trust-dev-cert
命令,没有任何错误,一切正常对localhost。



解决方案

您好,


这是一个已知问题,您可以查看以下主题。


https ://github.com/SharePoint/sp-dev-docs/issues/441


我建议您使用Google Chrome  来调试SPFx网络部分,如官方建议。


https://docs.microsoft.com/en-us/sharepoint/dev/spfx/debug-in -vscode


最好的问候,



I've just started developing client side web parts using SharePoint Framework 1.1.  Edge is my default browser.

I've set up a Developer Site on my O365 SharePoint tenant.  It was created using the Developer Site template.

When I run gulp serve, VS Code launches Edge to access the workbench on localhost, and everything works as expected.  However, if I attempt to load the workbench in my O365 tenant site with Edge (while gulp serve is still running) I get the following notice:

Your web part will not appear in the toolbox. Please make sure "gulp serve" is running in a web part project. Please refresh the page once "gulp serve" is running.

...and, as the notice suggests, my web part does not appear in the toolbox. :(

But when I open the same online URL in IE or Chrome, I don't get the warning and I can view my web part in the workbench with no problem.

Has anyone else experienced this problem and resolved it?  If so, what did you do?

Here is my environment:

  • Windows 10 Pro, all latest maintenance (including Fall Creators' Update)
  • Visual Studio Code 1.19.3
  • @microsoft/sp-build-web@1.1.0
  • @microsoft/sp-core-library@1.1.0
  • @microsoft/sp-lodash-subset@1.1.0
  • @microsoft/sp-module-interfaces@1.1.1
  • @microsoft/sp-office-ui-fabric-core@1.4.0
  • @microsoft/sp-webpart-base@1.1.1
  • @microsoft/sp-webpart-workbench@1.1.0
  • @types/chai@3.5.2
  • @types/mocha@2.2.47
  • @types/webpack-env@1.13.5
  • ajv@5.2.5
  • gulp@3.9.1

FYI, I've run the gulp trust-dev-cert command without any errors, and everything works fine against the localhost.

解决方案

Hi,

This is a known issue, you could check below thread.

https://github.com/SharePoint/sp-dev-docs/issues/441

I would suggest you use Google Chrome to debug SPFx web part as official suggested.

https://docs.microsoft.com/en-us/sharepoint/dev/spfx/debug-in-vscode

Best Regards,

Lee


这篇关于SharePoint Online,Framework 1.1和Edge - 无法使用Workbench的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆