Front end development foundation (JavaScript foundation III)

1, Scope 1. Global scope: It acts on the environment of all code execution (inside the whole script tag) or an independent js file. 2. Local scope: The code environment acting on the function is the local scope. Because it is related to functions, it is also called function scope. 3. JS has no block level scope: The block scope is include ...

Posted by harryman100 on Thu, 20 Jan 2022 10:29:20 +0100

MUI - chat window

preface Some time ago, MUI was used to make an APP, and the customer put forward ideas on whether to add a chat function to ensure the communication of all participating roles in the work order system. OK, arrange! Chat layout analysis We need to implement a chat window, and we need to give priority to the composition of its layout. Re ...

Posted by kee1108 on Thu, 20 Jan 2022 09:05:10 +0100

Vue learning notes 02

12, Axios 1. General Axios is a component used by vue to send AJAX requests, but it is not provided by vue 2. Related websites github: https://github.com/axios/axios 3. Installation and import install cnpm install --save axios vue-axios Import #Import vue and axios components import Vue from 'vue' import axios from 'axios' import VueA ...

Posted by sujithtomy on Thu, 20 Jan 2022 07:56:22 +0100

Prototype and prototype chain

1, What is a prototype Prototype: when each javascript object (except null) is created, it will be associated with another object. This object is what we call the prototype, and each object will "inherit" properties from the prototype. for example var obj = new Object(); When creating an object, an object will be associated ...

Posted by schoi on Thu, 20 Jan 2022 07:37:37 +0100

TypeScript advanced type 2 you need to know (summary)

Type inference: If no type is explicitly specified, TS will infer a type according to the rule of Type Inference: let myFavoriteNumber = 'seven'; //No mistake myFavoriteNumber = 7; //Type 'number' is not assignable to type 'string'. Note: different from declaring no assignment, declaring no assignment will be set to any ...

Posted by rndilger on Thu, 20 Jan 2022 06:06:48 +0100

Recent bug collection

The four front-end bug s in the recent personal learning process are only personal records. Please be careful for reference! catalogue bug [ @multi (webpack)-dev-server/client?http://localhost:8080 webpack/hot/dev-server ./src/main.js ] Bug ['Vue cli service' is not an internal or external command, nor is it a runnable program] bug [ npm ER ...

Posted by ManicMax on Thu, 20 Jan 2022 02:49:34 +0100

vue advanced: computed VS watch

Chestnuts Let's start with an example <template> <div> <input type="text" placeholder="Please enter a to-do" @keyup.enter="insertTodo" :value="todo"> <ul v-for="(todo, i) in todos" :key="i"> <li>{{ todo }}</li> </ul> <!-- It's complicated,It is also c ...

Posted by elacdude on Wed, 19 Jan 2022 21:19:42 +0100

Vite + vue3 + Vue router + vuex + CSS preprocessor (less/sass) configuration guide - the most detailed series in the whole network

@[TOC](Vite+Vue3+Vue Router+Vuex+CSS preprocessor (less/sass) configuration guide - the most detailed series in the whole network) Official Chinese documents of Vite Vue3 official Chinese document Vue Router 4.x Official Chinese documents Vuex 4.x Official Chinese documents This article only introduces the detailed steps of using Vite to buil ...

Posted by My220x on Wed, 19 Jan 2022 21:03:13 +0100

Front end common interview basic questions

1, Self introduction 1.1 name, graduation school (can be said or not), project experience, age and working years 2, vue correlation 2.1 routing mode: the difference between hash mode and history mode 1.The appearance of the path: stay vue There are in the routing configuration of mode The most intuitive difference between options is url in ...

Posted by cleary1981 on Wed, 19 Jan 2022 20:48:00 +0100

ECMAScript6 coding specification

Normative content statement 1.1 variables For variables that are only valid in the current scope, let should be used instead of var. for global variable declaration, VAR should be used, but too many global variables should be declared to avoid polluting the environment // Not good const variables; const globalObj = null; // Not ...

Posted by shibiny on Wed, 19 Jan 2022 17:02:56 +0100