Basic operation of react (1)

1. Create react component The first step is to introduce the following three libraries: react.min.js - the core library of react React dom.min.js - provides DOM related functionality babel.min.js - Babel can convert ES6 code to ES5 code, so that we can execute React code on browsers that currently do not support ES6. Babel has built-in supp ...

Posted on Thu, 23 Jan 2020 08:37:39 -0800 by php-coder

VScode configuration prettier and eslint

In the front-end tool, if the prettier is used for code formatting, eslint performs error detection. Great help for front-end work Principle: The prettier and eslint configurations can be divided into two types: local configuration and global configuration. VScode will check whether there are user-def ...

Posted on Wed, 22 Jan 2020 06:06:06 -0800 by Shandrio

Webpack journey: packaging of multi page applications

In the previous few days of webpack, we talked about all the packaging for a single page, even for some scaffolding tools, the packaging of webpack pages is a single page. But when we need to package multiple html pages, how can we handle it? The packaging of multi page applications is not the content ...

Posted on Fri, 17 Jan 2020 04:21:28 -0800 by davejj

The simplest configuration of react routing

Preface vue has written a lot. I want to know more about react. In addition, we all say that typescript is very fragrant. So write a small demo project with react + typescript. Because the main purpose of the project is to practice the cooperative use of various technologies, so the implementation of ...

Posted on Fri, 17 Jan 2020 04:13:38 -0800 by GESmithPhoto

react - complete version of basic knowledge points (not updated)

main.js // Basic configuration import React from 'react' import ReactDOM from 'react-dom' import App from './App' //Master page for bringing in other components ReactDOM.render(<App />, document.getElementById('root')) //root is in the index.html page of public App.js // Basic configuration ...

Posted on Thu, 16 Jan 2020 08:21:49 -0800 by scratchwax2003

[redux] redux saga learning notes

Preface Writing this stuff almost makes my laziness to the extreme. I don't know where to write it, so I don't want to write it. But we can only improve by forcing ourselves to write step by step... What is Redux Saga In essence, Redux saga is the middleware of redux. Here Last redux article It c ...

Posted on Tue, 14 Jan 2020 18:10:36 -0800 by unknown101

52 RN note 10 differences between custom components in ES5 and ES6

1, General writing method of ES6 custom component //1. Import resources import React, { Component } from 'react'; import { Text, View } from 'react-native'; //2. Custom components class Greeting extends Component { render() { return ( <Text>Hello {this.props.name}!</Text> ); } } //3. Import ...

Posted on Mon, 06 Jan 2020 01:20:44 -0800 by Jason_London

Encapsulate the monitor page scrolling component based on react

A few days ago, I made a react pc project. Because the business needs to do the scrolling operation of the monitoring page, I found some methods on the Internet that are not ideal, so I just started to do it by myself. The code is as follows: /** * Document author: Beamon__ * Description: public component - monitoring page s ...

Posted on Sun, 05 Jan 2020 03:35:25 -0800 by trmbne2000

react.js from entry to mastery (4) -- basic use of components

1, Scenarios used by components (1) The amount of code in a. js file is too large for maintenance. (2) Some functions or styles are widely used in projects, and components play the role of encapsulating code. 2, Basic usage of components (1) When components are not used The code is as follows: constructor(prop ...

Posted on Sun, 05 Jan 2020 00:22:09 -0800 by rbragg

A small problem about the defaultValue property of Input component in Ant Design

Record a problem encountered in the use of Ant Design. The defaultValue property is assigned, and the page data is not updated (not displayed as expected) after the page interaction processing data. class Component extends React.Component{ constructor(props) { super(props); this.state ...

Posted on Thu, 02 Jan 2020 22:02:56 -0800 by terry2