Angular 2应用程序中的Disqus:显示相同的讨论. [英] Disqus in Angular 2 application: Showing same discussion.
问题描述
我有Angular 2应用,我在其中使用 ng2-awesome-disqus 组件.
I have Angular 2 app in there I use ng2-awesome-disqus component.
在页面上我有几个项目,并且每个项目都有一个讨论组件:
<disqus [shortname]="shortname" [identifier]="identifier"></disqus>
- 每个项目的
-
简称是相同的
标识符对于每个项目都是唯一的
identifier is unique for each item
我希望每个项目都经过独特的讨论,但都一样.
I would expect unique discussion for each item, but there are all the same.
推荐答案
默认情况下,disqus每页只允许一个小部件.我认为(实际上,我敢肯定),您的模块只能处理一个disqus小部件.看看服务代码.
By default, disqus only allows a single widget per page. I think (actually, I'm sure), your module can only deal with one disqus widget. Take a look at the code of the service.
您必须自己创建一个项目并管理多个窗口小部件,或者创建自己的组件(如果可能).
You have to fork this project and manage multiple widget by yourself or create your own component that will do that if possible.
此问题可能会有所帮助.
这篇关于Angular 2应用程序中的Disqus:显示相同的讨论.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!