1.0.13 • Published 6 years ago
ng-disqus v1.0.13
Installation
Install it with npm
$ npm install --save ng-disqus
Usage
Import DisqusModule
in the root module
import { NgDisqusModule } from 'ng-disqus';
@NgModule({
imports: [
// ...
NgDisqusModule.forRoot('disqus_shortname')
]
})
The paramter shortname
is the unique identifier for your website as registered on Disqus, make sure it is defined in your module.
Now you can add Disqus component
@Component({
selector: 'any-component',
template: `<ng-disqus [identifier]="pageId"></ng-disqus>`
})
export class AnyComponent {
pageId = '/about';
}