Reddit reviews JavaScript Patterns: Build Better Applications with Coding and Design Patterns
We found 17 Reddit comments about JavaScript Patterns: Build Better Applications with Coding and Design Patterns. Here are the top ones, ranked by their Reddit score.
ISBN13: 9780596806750Condition: NewNotes: BRAND NEW FROM PUBLISHER! 100% Satisfaction Guarantee. Tracking provided on most orders. Buy with Confidence! Millions of books sold!
http://www.amazon.com/JavaScript-Patterns-Stoyan-Stefanov/dp/0596806752
This absolutely.
Advanced
Medium
Old, but probably still relevant
Yet to be released, but you can get the in progress pdf from the publisher
Docs
The one that everybody recommends
HTML5 spec
HTML5Rocks
Latest Webkit News
Other than that build build build. Make demos and play. Ask questions here or on stackoverflow and read other people's code. Also, lots of great old JSConf videos out there.
First of all, don't worry too much about a single interview. A lot of interviewers don't really know what they're doing / why they are actually asking the questions they are asking. Usually, they're programmers--not experts at hiring people.
Having said that, you definitely want to be familiar with common "gotchas" and major issues in the languages/frameworks you will be using.
For JS, I recommend two books in particular: JavaScript: The Good Parts and JavaScript Patterns. I found these helpful because they cover all the major issues with the language and they are quite concise. These don't cover any frameworks like jQuery or Angular though--that's another matter altogether.
Also take a look here: https://github.com/h5bp/Front-end-Developer-Interview-Questions
There's a good chance the interviewers will straight up copy questions from this list and you researching the answers will be a great learning experience.
Yeah JS:TGP is really required reading for professional Javascripters. I've also heard great reviews of Javascript patterns by Stoyan Stefanov. The sample chapter is good, I'm hoping to buy it later.
Felix's Node Style Guide is good too (basic style guide) and has some good rules to apply to your normal JS as well as NodeJS.
After that, browse through http://javascript.crockford.com/
Learn the module pattern and it's prettier sister the revealing module pattern and understand how it works. I use RVM everywhere by default, pretty much.
Once you've done all the above you should be able to say confidently:
More generally;
General tips:
Install firebug, JSONView. Get a good editor; I've had good experiences with textpad (win), Komodo(mac) and sublimetext(x-platform). Worry more about readability and maintainability than performance in general.
A nice phrase I came up with the other day: Simple code doing clever things is great, clever code doing simple things is bad.
Read other people's code. Read the unminified jQuery source, and other libraries. Try writing pure JS before going down the heavy-reliance-on-jQuery route.
I've recently been working on my JS skills and heres a few resources I've found super useful:
Books:
Javascript Patterns
Javascript: The Good Parts
Javascript: The Definitive Guide (While an exhausive resource on the topic, this one is a bit verbose)
Web:
Mozilla's Javascript Guide (One of the best free online javascript guides/references.
How to Node (Tutorials on server-side Node.js)
Daily JS (Interesting JS related news)
Echo JS (Similar to above but updates less frequently)
Hacker News (This is more general tech news but there is a ton of useful web stuff, especially as node.js is currently a hot topic. Reddit actually spawned from HN)
Online Videos (free)
Douglas Crockford's Javascript Lectures (I would recommend these to anyone getting into javascript)
Pro JavaScript Design Patterns
http://www.amazon.com/JavaScript-Design-Patterns-Recipes-Problem-Solution/dp/159059908X
JavaScript Patterns
http://www.amazon.com/JavaScript-Patterns-Stoyan-Stefanov/dp/0596806752/ref=sr_1_1?s=books&ie=UTF8&qid=1303912468&sr=1-1
High Performance JavaScript
http://www.amazon.com/Performance-JavaScript-Faster-Application-Interfaces/dp/059680279X/ref=sr_1_3?s=books&ie=UTF8&qid=1303912468&sr=1-3
Object Oriented JavaScript
http://www.amazon.com/Object-Oriented-JavaScript-high-quality-applications-libraries/dp/1847194141/ref=sr_1_1?s=books&ie=UTF8&qid=1303912517&sr=1-1
JavaScript: The Good Parts
http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockford/dp/0596517742/ref=sr_1_4?s=books&ie=UTF8&qid=1303912536&sr=1-4
Everyone loves to swing from Crockford's nuts, but I found this book a little hard to read. I lack a CS background and I fully admit I need to re-read this book as last time I read it was beginning of 2009
JavaScript: The Definitive Guide 6th Edition
http://www.amazon.com/JavaScript-Definitive-Guide-David-Flanagan/dp/0596805527/ref=sr_1_1?s=books&ie=UTF8&qid=1303912643&sr=1-1
I just ordered this yesterday, the 5th Edition is the book that really kicked it off for me back in 2005.
jQuery is cool and all (as are all the other libs) but you should try to learn core JavaScript as much as possible.
Out of all knowledge I acquired over years, Javascript payed off the most. It just never gets old. And that was even before Node.JS took off! Still, it supports so many different paradigms (procedural, imperative, class based, prototype based, event driven, ...) contained in it, every new code I look at seems so unique in style and pattern. So congrats! (Yea, college was kinda off the mark there for me too).
[JavaScript Design Patterns] (http://www.amazon.com/JavaScript-Patterns-Stoyan-Stefanov/dp/0596806752/ref=sr_1_2?ie=UTF8&qid=1342784762&sr=8-2&keywords=javascript+design+patterns) by Stoyan Stefanov. Covers more than just design patterns in a traditional sense, but JS patterns of all kind, highlighting and explaining syntax one might not be familiar with along the way.
Call me a heretic, but I found ...The Good Parts to be lacking. While most of the advice is sound, readers are expected to take it as gospel without much explanation. Patterns shown also lack concise implementation examples, and the ones that do tend to rely on utility methods developed in earlier chapters, making it more difficult to use as a reference.
Not focused on Node.js, but the following helped me a lot:
​
As already said, not so much focused on actual Node.js, but those helped me to have a better understanding on what was "under the hood", so applying what learned to Node was automatic.
Edit: oh i forgot https://www.codingame.com/ to look at others people craziest things in JS :)
Read these books:
So while javascript doesn't have separate classes (yet, it will have them in ES6) it does have objects. An object is defined as a function.
So say something like
function Person(name){
this.name = name;
}
var bob = new Person("bob");
console.log(bob.name);
That works and is a way to create an object in javascript (there are others also). However you really get into interseting situations with inheritance. JavaScript has prototypal inheritance. Meaning you can set the "prototype" which is similar to base a class, the difference is that you can invoke methods on a prototype, but not have direct access to properties.
Here are topics worth looking at :
https://www.amazon.com/JavaScript-Patterns-Better-Applications-Coding/dp/0596806752/ref=sr_1_1?s=books&ie=UTF8&qid=1511332535&sr=1-1&keywords=javascript+design+patterns
I would like to add JavaScript Patterns, which has several ways to structure your code like this.
I was actually reading JavaScript Patterns before vither999 recommended the book he did. So i'll definitely check out the book you're suggesting too! Thanks!
There are people who believe JavaScript does not favor good programming styles (I do not support that statement). In my university this semester, a group of graduate students presented a 12-hour course in Python. In many cases, they compared the language with other scripting ones, such as JavaScript, with not so friendly remarks about the language itself and its ecosystem in general. I can understand this claim: JavaScript was created to favor simplicity. Back in 90s, the WWW was still young. Eventually, there was a need to add interactivity to Web Pages. There were many choices, but all of those possible solutions had a stiff learning curve. JavaScript was introduced as a simple scripting language for the web that would target non-developers (there was not such thing as web developers in mid 90s). Unfortunately, the standardization process of the young language (ECMAScript) was not organized with every major browser implement different set of its features (hello IE!). There were not such thing as Design Patterns for JavaScript (until someone introduced them in the wide audience). Years, passed, the Internet evolved, so did the language. There are many things to like about JS today, but this is out of scope of this post. I cannot find a single point of reference about this debate, there are discussions all over the Internet. If your goal is to write a post about this debate, then you have to search for the main arguments of "JS haters" and "JS lovers" manually. Also you have to understand where the term "programmers" refer to. Who is your reference? The Senior developer at a big company, a Junior one, random people that do not know the real aspects of programming, etc. Then you can start researching about the different opinions. Feel free to update your post if like to, but answering "Why people in general hate JS" is quite ambiguous.
You should read this book
i recently purchased JavaScript Patterns by Stoyan Stefanov and i'm quite satisfied with it. You should check it out too, think it will help you. Although author says it's not a beginner book, I think a person knowledgeable in other programming language(s) could make use of it.
I agree that http://www.w2lessons.com/2011/04/you-dont-know-javascript.html is a pretty good read for a beginner to go through.
In there he uses this pattern, (function(){})() which is very powerful and useful. He is however using what Crockford calls, "The dogballs pattern", and suggests that you do this instead
(function(){}())
although that seems to be a minor style point. I would also recommend reading js patterns and the book Javascript Patterns, this is of course after a more in depth review of The Good Parts. There is some really good stuff on YUI Theatre. It isn't just about YUI, and has some really great talks and lectures. Also you don't have to join an open source project, but you do have to keep hacking. I would recommend you to get a github account and start working on some basic js demos to show off. Then maybe come back and make a post here with the link and ask some people to review your code. You can learn a lot by making mistakes and people telling you. PM me if you want me to look over anything.