Skip to content

NodeBB Plugins

Discussion regarding NodeBB Plugin development.

1.8k Topics 15.0k Posts
Most Voted Plugins

Subcategories


  • Have a question about building a plugin? Ask here
    427 Topics
    2k Posts
    traarrrT

    Hi all,
    Well this is my first time writing a plugin which involves using client side hooks...
    For a start, i would want my plugin to listen to a hook which activates when the topic page is completely loaded and topic tools are loaded too.

    For which I wrote this function:

    'use strict'; /* globals document, $ */ $(document).ready(function () { function alertType(type, message) { require(['alerts'], function (alerts) { alerts[type](message); }); } console.log('nodebb-plugin-quickstart: loaded'); $(window).on('action:topic.loaded', notifyBox); function notifyBox() { console.log("in notify box"); alertType('success', "done") } });

    but this is not working... I can only see "nodebb-plugin-quickstart: loaded" on the console.

    Where am i going wrong here??

  • Need a plugin developed? Ask here!
    222 Topics
    1k Posts
    B

    @baris 👍

  • Rebuilding after plugin installation

    7
    0 Votes
    7 Posts
    1k Views
    C

    @PitaJ said in Rebuilding after plugin installation:

    This is expected behavior. After installing and activating a plugin, you are supposed to Rebuild & Restart. There's a special button in the ACP to perform this.

    Then there is no problem. Thank you for your answers.

  • 0 Votes
    6 Posts
    502 Views
    barisB

    index: false will cause it to not show up in the acp page. Remove that.

  • This topic is deleted!

    1
    0 Votes
    1 Posts
    2 Views
  • 0 Votes
    6 Posts
    2k Views
    R

    Thanks a lot @baris. It worked like a charm. Saw your commit on widget-essentials. Got to learn a lot.

  • This topic is deleted!

    2
    0 Votes
    2 Posts
    9 Views
  • 0 Votes
    3 Posts
    2k Views
    אשרא

    what code?

  • Writing a database driver for firebase

    9
    0 Votes
    9 Posts
    1k Views
    Smule CollectionsS

    @baris thanks for the clarification

  • 0 Votes
    3 Posts
    377 Views
    Varun Ganesh DV

    @baris Thanks.
    Please Give Solution for Ads.txt issue too.
    so AdSense Section is complete for NodeBB
    Is any way to add ads.txt?
    ive uploaded file through admin panel. but for google it needs like domain.com/ads.txt

    Link Preview Image How to add ads.txt ?

    AdSense showing error that ads.txt not found How to add ads.txt? AdSense want to get that like - https://domain.com/ads.txt How to add like that? In apache s...

    favicon

    NodeBB Community (community.nodebb.org)

  • 2 Votes
    22 Posts
    6k Views
    yariplusY
    Version 1.6.0 !! Now works with 1.13.x! Re-wrote code to use new hooks and promises. Compatibility changed to >=1.10.0
  • Plugins for admin APIs

    Unsolved
    1
    0 Votes
    1 Posts
    265 Views
    Ankit KumarA

    Hey everyone,
    I am currently running NodeBB v1.13.x and using bearer token for authorizations.
    I need to use some admin APIs http://localhost:4567/admin/manage/privileges , but right now , it is showing 403 error. Please let me know if there are some specific way to use admin APIs .

    Best Regards

  • plugin for pictures in chat

    1
    0 Votes
    1 Posts
    262 Views
    אשרא

    have?
    thank

  • 10 Votes
    40 Posts
    41k Views
    yariplusY
    New Release 1.5.1

    Back from the dead with a bunch of bug fixes, code rewrite to current node and NodeBB, and new pictures for the guide topic!

    Fixed crash if camo was not installed locally. Fixed crash if an incorrect url was specified. Fixed crash if installed on windows. Fixed settings not changeable after original setup. Removed old or useless hooks. Removed babel. Corrected dead links and emails. Changed compatibility to >= NodeBB 1.0.0 New docs!
  • Tenor GIF and Redactor Composer issue

    1
    1 Votes
    1 Posts
    226 Views
    M

    When using Redactor as composer, clicking 'New Topic' or 'Reply' button will create multiple GIF button. See screenshot below:
    38f42ee6-a16b-4899-a53a-f2fedbf4fead-image.png

    The GIF button multiplies every time I close the composer and reopen it. It doesn't happen if I'm using the default Composer.

    Anybody face the same issue?

  • Plugin Help - checkin2 and Points

    1
    0 Votes
    1 Posts
    250 Views
    K

    Has anyone (successfully) integrated "checkin2" or "Points" into their forums? I'm trying to find a way to track daily activity in my forum per member as well as gamify the experience

  • Plugins are not working. showing Not found error

    10
    0 Votes
    10 Posts
    869 Views
    julianJ

    You'll need to add it to package.json on your local machine, and then git commit it into Heroku... or something -- I don't really recall how Heroku works, but it's something like that.

  • Captcha plugin for guest posts

    1
    0 Votes
    1 Posts
    291 Views
    T

    Anyone know of a captcha plugin for guest users to be able to post in an open forum category?

  • Advanced Editor Plugin

    4
    0 Votes
    4 Posts
    780 Views
    T

    @julian said in Advanced Editor Plugin:

    You'll probably want to use the Quill Composer, which is our official (in development) WYSIWYG composer.

    You should be able to download it from the plugins list.

    😄

    Don't you use markdown here?

  • 1 Votes
    2 Posts
    447 Views
    gotwfG

    @Mark-Bevels

    So you want your static Gatsby site to be dynamic. Heh, you are not the only one to have given this some thought... 😜

    But... where's the "win" here?

    Security: Well, the moment you go dynamic you open the door much wider to crackers. Maybe some small win that your static content is "safe" and only comments system exposed.

    Narrow minded to only analyze a single vector though so lets take speed and performance. Well, a static article might load faster since now main potential bottleneck is backend db and script glue.

    On to stability: Maybe a bit more stable to only make comments dynamic?

    Maintenance: I question whether this pans out on the cost/benefit front because the moment you go dynamic you add a LOT to your stack. Admin that stuff takes time so you may as well leverage it for other stuff.

    So ye' needs to be rollin' up yer' sleeves and experiment to find where your sweet spot lies. I think I would be inclined to go with dynamic blog such as ghost (definitely not WP). Ditto on the wiki front.

    NodeBB is awesome sauce for sure but seems overkill for a blog comment system. Disqus sucks privacy & copyright wise but there are other 3rd party offerings w/less egregious terms, e.g. Muut and a couple others I don't recall off top of my head. Personally, I just do w/o comments. No interest/need in becoming an Internet Personality. I just toss some stuff "out there" for whatever it may be worth to whomever. Yeah, maybe missing some back and forth, contribs, etc. but when it comes to bloggin' I would rather spend my time writing than maintaining and sweating the next zero day exploit. Yeah, I am a freak.

    Be all that as it may....

    Perhaps these are the droids yer' looking for:

    Reflections on the Digital Sabbath

    Link Preview Image Reflections on the Digital Sabbath

    What is the Digital Sabbath? The premise is simple: To go without digital media for a whole day as a form of rest. The challenge then, is to go without digit...

    favicon

    NodeBB Community (community.nodebb.org)

    Have fun!

  • Plugins Like Donut for Slack

    1
    0 Votes
    1 Posts
    261 Views
    J

    Hi,

    New to nodeBB, was curious if there were any existing plugins that had functionality similar to the Donut App for Slack? In short it essentially is an app that randomly pairs people either within a specified channel (would be groups for NodeBB) or across multiple channels. I think this would be a cool way to go about building connections within a distributed online community.

    Tried to search through the plugins on npm list but didn't see much in that regard.

  • Read-API access via Javascript / jQuery

    Solved
    1
    0 Votes
    1 Posts
    801 Views
    dogsD

    Hey Guys!

    I'm trying to experiment with the NodeBB API. And I want to receive the data via jQuery.

    var rest_url = "https://my.nodebb.net/api/topic/10/my-title-here"; var json_object = []; function get_posts_from(rest_url, callback){ fetch(rest_url) .then(res => res.json()) .then((out) => { //DEBUG START console.log(out); //Debug END json_object = out; callback(); }).catch(err => console.error(err)); }

    I receive this error:

    No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.

    Is this just a config problem of the nginx server or do I have to adjust some settings in NodeBB to?

    Another question is: Do I need the csrf_token from https://my.nodebb.net/api/config for the read-api too or is it just for the write API?

    I also added * to Access-Control-Allow-Origin in ACP -> Settings -> Advanced. It didn't work.

    Greets

    Solution

    I added Access-Control-Allow-Origin to the site configuration via ngnix.

    Open your configuration of the page e.g. my.nodebb.net.conf in /etc/nginx/sites-available.

    There should already be a location / block.

    Paste this into the existing block:

    if ($request_method = 'OPTIONS') { add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Credentials' 'true'; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type'; add_header 'Access-Control-Max-Age' 1728000; add_header 'Content-Type' 'text/plain charset=UTF-8'; add_header 'Content-Length' 0; return 204; } if ($request_method = 'POST') { add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Credentials' 'true'; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type'; } if ($request_method = 'GET') { add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Credentials' 'true'; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type'; }

    THIS ALLOWS THE ORIGIN FROM * (everywhere) ITS NOT RECOMMENDED FOR PRODUCTION INSTANCES. I just use this to test my code locally on my machine.