【发布时间】:2017-10-19 19:53:48
【问题描述】:
我已关注quick start 并制作了一个有效的hello world webpart。
我想包含 twitter 小部件,所以我按照添加外部 JavaScript 的指南进行操作,this 链接自 git hub
我将以下内容添加到我的 config.json
"externals": {
"widgets":"https://platform.twitter.com/widgets.js"
},
我用
导入import 'widgets';
但是,我收到以下错误
***Failed to load component "ab3668f3-39a2-4b40-a307-a1bea4023df9" (TwitterWebPart).
Original error: ***Failed to load URL 'https://platform.twitter.com/widgets.js' for resource 'widgets' in component 'ab3668f3-39a2-4b40-a307-a1bea4023df9' (TwitterWebPart). There was a network problem.
This may be a problem with a HTTPS certificate. Make sure you have the right certificate.
网址https://platform.twitter.com/widgets.js 工作正常。
【问题讨论】:
标签: sharepoint spfx