I am able to solve this issue. I needed to add checks in map.tpl instead of relying upon pure client-side JS solution.
Native electron client
I'm currently using Electron to build a desktop client for an Express app which just transforms API JSON responses into views.
Now I was thinking it would be great to have a boilerplate, customizable NodeBB client built with Electron. It could be customized to fit the board style, use real OS notifications, open chats in real modal windows, integrate better file browsing and upload and so on. I bet gaming board developers would also be pleased to have native Steam integration etc.
Would anyone be interested in building such a client together?
@teh_g sadly, this won't be possible with Electron, since it requires V8, Chromium and Node.JS to run, all of which are not available on neither iOS nor Android.
You could maybe use Cordova for this, but it would require a C# developer, store licenses etc... not forget a great amount of time and effort.
Electron, on the other hand, makes developing Desktop applications with JS easy and really quick... So it would be quite easy to craft a NodeBB client. I imagine board admins could run an installer like
npm install nodebb-electron-client-setup, then do
npm setupand have the client available for download at
http://example.tld/client/:osfor their users.