How did you learn Node.js and/or Javascript?

General Discussion

Suggested Topics


  • 0 Votes
    3 Posts
    381 Views

    A custom server? We do that all the time unless "custom" means something I am unfamiliar with 😁

  • 0 Votes
    3 Posts
    2k Views

    @baris Hm was doing similar approach, please check my another question with path.js error.

  • 2 Votes
    10 Posts
    3k Views

    @omega That's right, if shutting down redis over and over again is saving old data into the dump file, then Redis itself is not shutting down properly.

    Redis itself never persists anything into memory (or rather, it shouldn't) once it shuts down, it's all dumped to disk.

    Are you sure it's stopped? Check ps aux | grep redis for any errant processes. What does the redis log file in /var/log say? Any errors when shutting down?

  • 0 Votes
    21 Posts
    10k Views

    @frissdiegurke when using document.write you can avoid replacing the whole site, but it cannot be loaded asynchronously aka injected (as it needs to execute immediately on DOM build), which is most likely the case on most NodeBB pages

    @DennisSun if you want to have a dynamic the protocol, or maybe that string at the end, use something like

    <script type="text/javascript"> (function() { var something = '0da233db09b6a0886cd3f9d1a52e64d8'; // or could be dynamically generated, I don't know // build your script tag var script = document.createElement('script'); script.type = 'text/javascript'; // that's useless, browsers ignore it, but whateves script.async = true; script.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'hm.baidu.com/h.js?' + something; // google analytics does that, this will find this actually script (unless loaded asynchronously, in that case it would find the last script tag on the page) // it should work in either case // var thisScriptTag = document.getElementsByTagName('script')[0]; // thisScriptTag.parentNode.insertBefore(script, s); // or you can just append it to the head var head = document.getElementsByTagName('head')[0]; head.appendChild(script); })(); </script>
  • 0 Votes
    5 Posts
    2k Views

    @sp4rkr4t all i did was run

    sudo ./nodebb start

    but now i realize how old this topic is