Development Ideas :
1. How to load JS.
(1) A JS text, load JS method: Directly in the page to write code or use script to introduce
(2) Multiple JS text, load JS method: Use Seajs to manage some JS text.
Seajs is a JavaScript module loading framework which follows the CMD specification, which can realize the modular development and loading mechanism of JavaScript. Related code, case
(3) Use the Grunt-cmd-transport plug-in to package some. js text into a. js text.
Webpack, code packaging tools.
Grunt is a node.js-based project building tool. It can automatically run the tasks you set. Grunt has a large number of plug-ins, almost anything you want to do can be achieved with grunt. 2. How to develop efficiently and reduce errors.
(1) Set development specifications: You can refer to "Google JS code specification"
(2) Develop code templates
(3) Front-End code check with the Grunt-contrib-jshint plug-in 3. Interface iterations frequently, how to avoid frequent changes in front.
Unified Bottom Entrance 4. Many pages exist to interact with each other, how to reduce code redundancy and facilitate maintenance.
(1) If the UI is not involved, that is, a simple implementation of a function and multiple use-front-end function library
(2) If the UI, that is, "window"-Components eg: DMS online or business card function 5. The page is too complex, features too much, strong correlation, where the code is written.
Modular development
Eg: Each type is a module, fill in the blanks or select a single, etc. Development Recommendations : 1. Emphasis on fundamentals (grammar, common libraries, General solutions, debugging) 2. Strictly Follow code specifications 3. Standalone, generic, optimized 4. Extensively dabble, practice, think more