Lifecycle of React components

1. Overview of component life cycle Significance: the life cycle of components is helpful to understand the operation mode of components, complete more complex component functions, analyze the causes of component errors, etc.**Component life cycle: * * the process from component creation to mounting to running on the page, and then to componen ...

Added by DickDeeds on Wed, 05 Jan 2022 23:02:50 +0200

HTML basic Tags

Today's class content 1. Pre class review 1.1 basic structure of HTML: html,head,body 1.1 common Tags: br, hr, font, h1-h6, p, ul, ol, img, marquee, etc. 2. Content of today's new lesson     2.1 use of hyperlinks < a > 2.1.1 attribute href: hyperlink address                  2.1.2 you can jump between local and web pages            ...

Added by azn_romeo_4u on Wed, 05 Jan 2022 21:23:39 +0200

Differences among split, slice and split in JS

I often meet these three when doing questions these days. They look very similar. I have to find them every time, so I also record them this time. 1, splice() method The splice() method modifies the array by deleting or replacing existing elements or adding new elements in place, and returns the modified contents in the form of an array. (this ...

Added by premracer on Wed, 05 Jan 2022 19:36:42 +0200

Detailed explanation of three elements of Vue Router: route map, route view and route navigation

Using Vue router module Install the Vue router library before using Vue router cnpm install vue-router –save Three elements of Vue router Route map, route view, route navigation Route map refers to the mapping relationship between route and component; Route view refers to the rendering location of the corresponding component of route mappi ...

Added by mattotto77 on Wed, 05 Jan 2022 18:58:38 +0200

[JavaScript] < object oriented > function method & object creation & prototype object & scope analysis

Catalogue 1, JavaScript data type: Classification of objects: 1. Built in objects: 2. Host object: 3. Custom object: 2, Operation of object properties: 3, Basic data type & reference data type: 4, Object creation: Create objects using object literals: Create objects using factory methods: 5, Function function: 1. Creation of f ...

Added by RadGH on Wed, 05 Jan 2022 17:16:59 +0200

Front end unit test 03 Sion

Front end unit test 03 Sion Problems in front-end test Before talking about Sinon, we have to talk about some problems in our front-end testing after learning Mocha, chai and enzyme. For example, the foreground test needs to interact with the background, and then test according to the corresponding data after obtaining the background data. For ...

Added by dancing dragon on Wed, 05 Jan 2022 16:51:03 +0200

day_ Regular expression of 21 JS

1, Regular expression: Verification (validation) of string -- string Regular creation Literal create / match string/ Instantiate object new RegExp('matching string ') / / double slash --- judge whether there are characters in the string that can match good         const reg1 = /good/ / / short for regular expression / / instan ...

Added by Hatch on Wed, 05 Jan 2022 16:19:37 +0200

Huxiang cup 2021 Pastebin recurrence learning

Huxiang cup 2021 Pastebin recurrence learning 1, Introduction to Service Worker Service Worker can be understood as a proxy server between the client and the server. When a Service Worker is registered in the website, it can intercept the request and judge whether to send the request to the server or directly return it to the client through t ...

Added by ashutosh.titan on Wed, 05 Jan 2022 16:08:44 +0200

How do I interrupt an outgoing request?

Recently, I met the problem of how to interrupt the web request that has been sent. I'll discuss it with you here. Interrupt axios request axions interrupt requests can be made in two ways: Mode 1 Use canceltoken The cause factory method creates a cancel token with the following code: import axios from 'axios' const CancelToken = axios.Can ...

Added by nrerup on Wed, 05 Jan 2022 15:24:02 +0200

jQuery self study notes

1, Selector for JQuery 1.1 basic selector nameusagedescribeid selector$('#id');Gets the element with the specified IDClass selector $('.class');Get elements of the same classtag chooser $('div');Gets all elements of the same class of labelsUnion selector$('div,p,li');Use commas to separate as long as one of the conditions is metIntersecti ...

Added by dfarrar on Wed, 05 Jan 2022 15:16:23 +0200