Are there any good design methods or standards for developing JavaScript?

When developing with object-oriented languages ​​such as Java or C #, developers often have to use design tools such as UML to create class diagrams, create interfaces, define basic components and interactions, describe APIs, etc., before start implementation.

I know that for most small JavaScript applications, these software development principles may be excessive, but if you are developing a library (jQuery, YUI) or creating a large application (Gmail, Google Docs), it is a good idea to create a design and plan ahead You will start writing any code.

Are there any similar methods used in JavaScript development or web development in general?

Edit:

Just to clarify, I'm not interested in creating classes / interfaces or creating UML for JavaScript. JavaScript is a different paradigm from the likes of Java / C # and therefore needs a variety of design tools. I’m interested to know what JavaScript development tools and techniques are, if any.

Perhaps this question will be better asked, what I would like to know: if a company such as Google created a large web application and created several dozen team members, what processes, documents and methods could use such a team to successfully create, to collaborate and strengthen design? What tools (for example, UML, flowcharts, scratched notes on a piece of paper) will be used to work and share the design of the application (without writing a single line of code)?

+4
source share
2 answers

I am a fan of the Google Javascript Style Guide:

https://google.imtqy.com/styleguide/javascriptguide.xml

+8
source

I think the answer depends a lot on which libraries, if any, you are using on the client side.

Jquery code is very similar to Sencha or Sproutcore code, for example. In Sencha and Sproutcore, the framework provides you with a β€œcool” system for developing components, so this framework lends itself to canonical forms of design.

Also note that javascript is very different from Java or C #. You can impose an interface type system on your code, but many claim that you kill the javascript dynamics of a dynamic language if you do.

However, it is always good to have a plan. If you can remain DRY by extending JS objects, then I think you need to. And it always makes sense to put some design at a high level.

+1
source

Source: https://habr.com/ru/post/1340196/


All Articles