October 18th, 2015, 05:52 PM
Advice on JS development
I finished a qualification in Web Development last year and have been using a lot of PHP (fairly vanilla stuff) for some clients as part of a freelancing thing. I've also been using the same technology for the sites I've been making at work. They use PHP e-commerce plugins, so we thought we might as well go with a PHP front-end as well.
However, I recently saw a graph saying that node.js is the fastest growing framework, so I thought I'd try it and I really like the basic framework, I just need more functionality and I'm not sure if I should use Angular.js, Vue.js, React.js?
I'm going with MongoDb for now. If I remember correctly, I chose it because I don't really need an Excel style database, just a user/password/content type thing.
Can I get some advice as to what other people are using and why? What they like and what they don't? Just so you know, I'm trying to develop a pretty basic social media type app, at the moment.
October 27th, 2015, 11:27 PM
Additionally, looking into things like RequireJS and ES6 (the newest standard) are more or less necessary.
The goal, after all, isn't just to create web pages anymore. You need to be able to create Web Applications That Mimic Desktop Applications. Real time as possible, interactive as possible.
A few thoughts on specific JS libraries before I head to bed:
Kind of indepensible, great cross-browser support, and makes transversing the DOM so much easier, but a lot of tutorials also encourages a lot of bad behaviors. For instance, every time you see something like "data-*", take a shot. Never mix data and templating, anywhere.
My personal favorite, but it also has a really steep learning curve. Factories, service providers, dependency injection. Things that I'm right at home with, but something that can confuse a lot of new people.
Strengths: Built-in templating system, making it easy to separate views from models from controllers. Large ecosystem with a lot of stuff easy to get right off the shelf. As fast as your server connection can make it (i.e, templates are loaded once per load of the application).
Weaknesses: Insanely hard to get into. Learning how Angular does scoping is enough to keep you away. Also, 1.* is on the way out, and 2.0 looks kind of bad, so I'll probably jump ship to Ember or a mix of React with something else
All the strengths of Angular, but some of the weaknesses of jQuery. If you know what you're doing and have a solid foundation, it's fantastic.
Strengths: lots of great built-in functionality, easy to debug
Weaknesses: Not a huge eco-system to be honest, so if you find yourself in a situation, be prepared to build something.
Flux is not a web application framework. It's only for displaying stuff. It provides little to no support for models, controllers, or making waffles.
Strengths: It does some cool stuff, but...
Weaknesses: It's a pain in every sense. Just ignore it and go about your busness.
Backbone lets you build applications. It, with a templating engine and jQuery, is extremely powerful.
Strengths: Lets you decide what is best. Works great with RESTful backends, great documentation, etc.
Weaknesses: Chooses the "configuration over convention" path too often.
Also, a note on MongoDB: just don't. It's a nice idea, but CouchDB is much better and more reliable (and even then, you probably shouldn't. We made the decision to use Cassandra in our warehouse system since a) it had to be distributed and b) it had to be fast, but that's an edge case. We still did weeks of research and stress tests).
Comments on this post
October 29th, 2015, 10:23 PM
Thank you @oakleaf. I'm glad someone took their time to give us noobs a few words. I'll look into that definitive guide book. The things you mention about web apps mimicking web apps is kind of what I was thinking of doing. Also, the tip on Db's is great too.