You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using the following in React to use NodeBB as comments. While the articles are created, the title of all is undefined. What are the proper variables to set to make this work properly?
function loadScript(src) {
return new Promise(function (resolve, reject) {
var s;
s = document.createElement('script');
s.src = src;
s.onload = resolve(s);
s.onerror = reject;
document.head.appendChild(s);
});
}
componentDidMount() {
const { articleID } = this.props;
var nodeBBURL = 'https://mysite.xyz';
let obj = {
title_plain: 'this is page 2',
url: 'http://mysite.xyz',
tags: ['awesome'],
markDownContent: 'Sometimes life can be **bold**.',
cid: 5
}
window.articleID = articleID;
// articleData is not being used; site title is `undefined`, no tags
window.articleData = JSON.stringify(obj);
window.nodeBBURL = nodeBBURL;
loadScript(nodeBBURL + '/plugins/nodebb-plugin-blog-comments/lib/general.js')
}
The text was updated successfully, but these errors were encountered:
I am using the following in React to use NodeBB as comments. While the articles are created, the title of all is undefined. What are the proper variables to set to make this work properly?
The text was updated successfully, but these errors were encountered: