I
I
Ivan Antonov2015-09-09 15:21:58
JavaScript
Ivan Antonov, 2015-09-09 15:21:58

How to design a JavaScript application?

In JavaScript, in my opinion, it is easiest to get confused in the code, especially when building complex applications. Recommend material on patterns and design in general for JavaScript.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
Sergey, 2015-09-09
@antonowano

First, understand the principles of object-oriented and functional programming. Stuff like "why is high code coupling bad, why do we need MVC, etc."
In parallel, you can deal with typical design patterns for js: largescalejs.ru
And one more thing - ES2015, active use of modules and things like jspm/webpack for assembly. In fact, all the problems in js are crooked dependency management (the whole point of OOP, in principle, is dependency inversion, functional approaches do everything even better). Now the situation with all this is much better than it was, say, 4 years ago.
Again, when it comes to really big projects, you should stop writing on every sneeze your bike. We need a library for organizing routing - we take a ready-made one. We need to work with dates - we take moment.js, etc. Builders like the same jspm are able to pull out what is possible from popular libraries (if you can do this, say with angular2 you can pull out only the necessary modules, but not with angular1).

D
Dmitry Kovalsky, 2015-09-09
@dmitryKovalskiy

Writing crap in any language is equally easy. Search the toaster for "javascript architecture". Well, or in search engines by adding the word "applications"

R
Rafael™, 2015-09-09
@maxminimus

This language is very simple
In simplicity, it is comparable to C.
It only depends on you how your application will be arranged - it is difficult to understand or vice versa
Difficulties and incomprehensibility almost always arise when you want to use ready-made frameworks Do
everything yourself or suffer like everyone else
and decipher someone else's code
And working only for yourself selling in the appstore - you don't owe anything to anyone and you can do it simply and clearly and conveniently
Beginners must be able to invent original bicycles
Otherwise laziness and office slavery win

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question