I use it to cloak results. Is it easy to learn? I'm not sure I've learned anything. I usually just read-up, try a couple experiments and end up getting the results I want, then stop "learning."
NickMNS
11:26 pm on Apr 21, 2018 (gmt 0)
My understanding is that node.js is a server side JavaScript engine that allows you to execute JavaScript server side. I don't use it, at least not yet. Typically js is executed client side but with node it allows you to write and run scripts on your server. It is interesting to use if your app or website runs in js as this will allow you to do all the scripting in one language. It is often used with Angular or React. As I delve further into the realm of PWA's and service worker they may come a time when running node will make sense for me. I haven't reached that point yet.
Is it easy to learn? It is JavaScript.
Travis
10:37 am on Apr 22, 2018 (gmt 0)
Thank you for your feedback.
keyplyr
10:52 am on Apr 22, 2018 (gmt 0)
One thing you may like is its speed. I switched my sniffer script originally in php to node.js because of faster speed and the fact I never did like the vulnerabilities of php.
iamlost
4:21 pm on Apr 22, 2018 (gmt 0)
As is often the case in webdev while each 'tool' has it's fan base that says it's the solution to everything it's really a matter of selecting the best tool available for the requirement at the least cost. NodeJS is just another tool. The question to ask is what problem does it solve for you and does it do so sufficiently better than current usage tools to be worth the learning curve, writing, testing, and rollout.
NodeJS is asynchronous, event driven I/O; each instance runs in a single thread that being asynchronous can handle far more concurrent requests than, say, Apache, which is thread and process based meaning each request is handled by a separate thread/process such that while waiting on I/O the whole thread is blocked. On the other hand if a NodeJS instance fails one should expect (there are mitigating best practice bulwarks) that all information within thread is lost. There are pluses and minuses to every system.
NodeJS is mostly used in 'live' situations such as gaming, chat, single static page updating (aka AJAX modern) web pages where it is pulling from in memory resources; where it falters is in normal DB calls.
I use Apache running on Debian with PHP for ye olde DB serving and NodeJS fronting Redis for real time analysis and predictive/preemptive analytics to power personalisation, behaviour identification, bot defences, contextual delivery, etc.
Re OQ: if you are conversant with Javascript learning NodeJS should be relatively straightforward. If your use case also requires learning a framework/library, i.e. express.js, meteor, sails.js, that adds complexity while offering, perhaps, a foundation.