1. Promise (read)
2. Axios (Read)
3.Vue publishing and Subscription (read)
4.Vue Diff and virtual DOM:
-
Vue draws on snabbDOM, a virtual DOM library, and diff algorithm.
-
Virtual DOM: Use JS objects to describe the DOM hierarchy.
-
The new virtual DOM and the old virtual DOM diff to calculate the minimum number of updates, and finally reflect the real DOM.
-
The DOM becomes the virtual DOM for the content compiled by the template.
-
H function: used to generate a virtual node. Virtual node attributes: children, data, ELM (not mapped to the DOM tree), key, SEL, text.
-
Diff algorithm: Compare only on the same node. Same selector and same key. Generally, the parent node is not changed when used, so the impact on efficiency is not significant. Only the same layer comparison, not cross-layer comparison.
-
The virtual DOM becomes the real DOM.
-
Virtual DOM plus key to achieve the minimum update algorithm.
5. WebPack related:
-
–save-dev records the installed package and the version number in the devDependencies object in package.json. Save — dev to devDependencies
-
Configuration file:
-
File entry
-
Runtime environment
-
Loaders used: For which files and loaders are used
-
Package path and file name
-
The difference between plugin and loader is that loader matches different Loaders to process this file according to different file names during import.
Plugin, instead of focusing on file format, fires different events at each stage of compilation, allowing you to intervene at each stage of compilation.
-
- Whether the new chunk is shared or from the node_modules module
- Whether the new chunk size is greater than 30KB before compression
- The number of concurrent requests for loading chunk on demand is less than or equal to five
- The number of concurrent requests during initial page loading is less than or equal to 3
6. A few classic layouts:
7. Hand-write the Flex layout
8. Vue component communication
9. Bidirectional binding principle of Vue: