1. Use the random library to generate 10 random numbers between 100 and 200, and find their maximum value, mean, standard deviation and median. # 1. Use the random library to generate 10 random numbers between 100 and 200, and find their maximum value, average value, standard deviation and median. import random # define a […]
Tag: modularization
Understanding of Android componentization/modularization!
Original source Title: Understanding of Android componentization/modularization! Author:The moving turtle Original link: Understanding Android componentization/modularization! Foreword Nowadays, componentization is really not a new thing. Large companies are very familiar with it and are very familiar with it. That is to say, some medium-sized projects and small projects are now working hard on the road of […]
Eleven: Vuex, getters, mapState, mapGetters, mapActions, mapMutations, multi-component shared data, vuex modularization
一.vuex 1.vuex introduction What is it? vuex is a vue plug-in that implements centralized state (data) management in Vue. Centralized is like a teacher teaching a group of students, and the state is data; Vuex centrally manages (read and write) the shared data of multiple components in Vue applications, and is suitable for communication between […]
8. Modularization of ES6
ES6 introduces modularity. The modularity of ES6 is divided into two modules: export @ and import. ES6 modular features: (1) ES6 modules automatically enable strict mode, regardless of whether you add use strict; to the module header. (2) Various types of variables can be imported and exported in the module, such as functions, objects, strings, […]
commonJs+AMD+CMD+ES6 modularization
Write the directory title here nodejs CommonJS Export of modules Import of modules The problem with browser-side modularity AMD CMD ES6 import and export Basic export and import of modules Default import and export nodejs Install nodejs Official website address: https://nodejs.org/zh-cn/ The browser runs the html page and loads the js introduced through the script […]
[ES6 knowledge] ESModule modularization
Article directory 1. Foreword: Modular background 1.1 Backend modularization 1.2 About front-end modularization 2. Export of modules 3. Import of modules 4. Apply modules to HTML 5. export default default export command 6. Rename export and import 7. Create module objects 8. Dynamically loading modules 1. Foreword: Modular background JavaScript programs are inherently small – […]
Node.jsModularization:
Article directory 1. Basic concept of modularization 2. Modularity in Node.js 【1】Classification of modules in Node.js 【2】Load module 【3】Module scope 【4】Externally share members in module scope 【5】Modular specification 3. npm and packages (packages/dependencies/plug-ins) 【1】Basic knowledge of packages: 【2】Develop your own package 【3】Release package 4. Module loading mechanism 【1】Load from cache first 【2】Loading mechanism of built-in […]
webpack (1) Modularization
Modular evolution process Stage 1: File-based module division method Concept: Put each function and related data state in a separate file It is agreed that each file is a separate module. When using each module, directly call the members of this module. Disadvantages: All members can be accessed and modified outside the module (all modules […]
JavaScript modularization process (2)
Article directory 4. Modular Standard Specification (ES Modules) 4.1 How to use ES6 specifications 4.2 Strict mode 4.3 Actual use 4.4 Default export 4.5 Order of loading files Reference article 4. Modular Standard Specification (ES Modules) The modular solution provided by ES6 is called ES Module, or esm for short. Now I have basically come […]
Modularization of front-end engineering
Modular background Front-end modularity is a standard, not an implementation Understanding modularity is the prerequisite for understanding front-end engineering Front-end modularization is the inevitable result of the scale of front-end projects What is front-end modularization? Front-end modularization is to split complex programs into several modules according to specifications. One module includes input and output. Moreover, […]