Get started with React routing quickly without nonsense

This article aims to be concise and help you get started quickly. By default, you have been exposed to routing related development install Enter the following command to install: // npm npm install react-router-dom // yarn yarn add react-router-dom React router related labels There are eight common components of react Router: import { ...

Posted by xtiano77 on Thu, 10 Feb 2022 06:04:03 +0100

Web Components series - create Custom Elements

preface According to the previous introduction, we know that custom elements can be divided into two categories according to whether they inherit basic HTML elements or not“ Autonomouscustom elementsCustomized built-in elements This raises a question: what is the difference between the two in use? Let me try to explain this problem ...

Posted by henkealf on Thu, 10 Feb 2022 00:45:18 +0100

js basic ~ array, object, function, math object, DOM node

1. Array (1) When storing multiple data of the same type, you can use array, which is a reference type. Two ways to create arrays //The first creation method Use the new keyword var nameList = new Array(); //The second creation method uses [] literal. var nameList = []; (2) Data is stored by index (sequence number) in the number, and t ...

Posted by v3nt on Wed, 09 Feb 2022 22:02:11 +0100

GEEer Growth Diary 9: worldpop100 m resolution population data visualization and batch download

Recently, I saw many small partners looking for Worldpop population data. When Xiaobian went to see it before, the national image was about 4G, which was too big. However, Xiaobian has collected data for all the people in China, focusing on WeChat official account: GEEer Growth Diary. Available. Today we mainly talk about how to use GEE to dow ...

Posted by joe__ on Wed, 09 Feb 2022 20:53:18 +0100

Using craco to optimize the construction of cra project

Modify the configuration of CRA project A project created with create react app cannot modify its internal webpack configuration by default. Unlike Vue cli, it can be modified through a configuration file. Although an eject command can completely expose the configuration, it is an irreversible operation and will lose the convenien ...

Posted by ajcrm125 on Wed, 09 Feb 2022 16:49:55 +0100

Module module in ES6

Before ES6, JavaScript had no module system, so it was impossible to split a large program into interdependent small files and assemble them in a simple way. The community has developed some Module loading scheme , the CommonJS specification is very good, but it is not applicable to the browser environment, so there are two schemes: AMD and CMD ...

Posted by Ixplodestuff8 on Wed, 09 Feb 2022 12:34:26 +0100

Differences and relations between JS array, JS object, json array, json object and json string

1. Concepts of arrays and objects 1 array In the computer, the array storage mode of basically any language (plus basically because I don't understand all languages...), All data (or elements) of the same type are continuously stored in the address space, and they are also very similar in form, so it can also be described as this. An array is ...

Posted by johnnyblaze1980 on Wed, 09 Feb 2022 11:47:18 +0100

Principle analysis of on-demand loading

brief introductionUnderstand the basic knowledge of Babel plug-in and the internal principle of on-demand loading. I'm no longer afraid of the interviewer asking me the implementation principle of on-demand loading.import { Button } from 'element-ui'How did it becomevar Button = require('element-ui/lib/button.js') require('element-ui/lib/theme- ...

Posted by TheVoice on Wed, 09 Feb 2022 09:13:07 +0100

bootstrap implementation of rotation map - Daquan

As we all know, there are many ways to realize the rotation. For example, writing in pure js is time-consuming and laborious, and it is not suitable for all kinds of terminal devices, but bootstrap is different. You only need to write a set of code, which can be used normally, whether on the mobile phone, ipad or PC. How to create a rotation ...

Posted by MarCn on Wed, 09 Feb 2022 07:48:28 +0100

Understanding of http, ajax and json, encapsulation of handwritten ajax

HTTP 1. HTTP – Hypertext Transfer Protocol 1.1 HTTP three points: No connection: limit each connection to one requestIndependent: the client and server specify the MIME type of transmission, and any data type can be sent through HTTP [content type. PDF is the MIME type]Stateless: it means that the agreement has no memory ability for th ...

Posted by Jeannie109 on Wed, 09 Feb 2022 05:11:29 +0100