there are two child components in a parent component, which are component A, component B. Component An is the name of a list of data, and component B is a data form formed by a single piece of data of component A. how to make component A re-render after ...
I have two react projects, using two similar sets of components. Most of the project A components and project B components are the same, but individual components are different. The components in them are written by themselves and often need to be chang...
recently, I am learning the framework of react. I have only used a single-page application before, but now I want to use it to build a multi-page forum application. If I encounter some questions, I will ask my predecessors to answer them. I now get th...
...
configure redux-persist according to the tutorial. It is true that redux data is stored in localstorage, but it is all initialized data. The code is posted below. store.js import { createStore } from redux import { persistStore, persistReducer } ...
the code in setTimeout in the react-native project executes immediately, but the cause is not found, and the problem is not found in the react project. if setInterval is used, it will also be executed immediately, and then triggered at a normal time. ...
recently I am learning react, and want to try to be a todo. But there was a problem when the parent component passed the value to the child component parent App: class App extends Component { constructor(props){ super(props); this.state = {...
1. import React from react const Demo = () => { return ( <div>sd< div> ) } export default Demo 2. import React from react class List extends React.Component { render() { return ( <div>sd<...
use the original table component to encapsulate an extra layer of TableC, in the render method of the columns property to render switch, circularly. No matter how you modify the data view, it will not be updated, including using mobx, to ask how to solv...
ask for documents about react-native calling NFC-related APIs. Baidu can t get a link from the boss ....
Hello everyone, if I want to simulate a change event of a text box on a react website. and I don t have react source code. I want to write code simulation on chrome s console. What should I do? if it s your own react project, it s easy to simula...
step 1, in parent component: constructor(props) { super(props); this.state = { checkState: checked , enable:true } } this.setState({ checkState: unChecked , enable:false }) step 2: before calling the subcompon...
* deleteDetails({payload}, {call, put}) { const result = yield call(deleteDetails, {payload}); if (result.code !== 200) { throw result.msg; } else { Toast.success(result.msg, 1); yield put(routerRedux.goBack(...
such as the title, it is very strange. if you write this sentence "parser ": "babel-eslint ", you won t check it directly ...
redux-thunk const fetchData = (params) => (dispatch) => { setTimeout(() => { dispatch({action: GET_DATA , payload: 111}) }) } dispatch const fetchData = (params) => ({action: GET_DATA , payload: 111}); setTimeout(() =>...
app.js import . app.scss ; app.scss $vw_fontsize: 75; @function rem($px) { @return ($px $vw_fontsize ) * 1rem; } $vw_design: 750; html { font-size:($vw_fontsize ($vw_design 2)) * 100vw; @media screen and (max-width: 320px) { font-size...
as mentioned, I have a project with multiple components, all of which have some event handling and operations. And different action events within these components may result in the same result, including updates to the redux. for example, I have two m...
question: why doesn t the style work when an object is put into style= {} in react? Code: loadCssFunc = ()=>{ return { color: red , fontSize:12 } } render() <div style={this.loadCssFunc}>< div> can t b...
for example, there are two modules on the page now, one with the "more " button when you click more, the pop-up Modal, shows more. After closing, click another "more ", you will see the data in Modal flickering into new data, how to solve this pr...
1. Problem: when using antd s Modal.confirm, put an Input, to update the txNote property in state. But as long as there is a confirm, all you get is the previous state, instead of the updated state 2 entered in the confirm. Screenshot: 3. From...
code is as follows: columns2: [ { title: , key: type , align: left , width:120 }, { title: , key: item , align: left , width:1000 }] ...
When the project uses tree to display information, sometimes the user needs to select only one value, that is, radio selection. the ui framework of iview is used in the project. If I only have to select a single node, checkbox can only choose one e...
problem description Project editing can be deployed under tomcat, but cannot be started under idea use the platform fedora 28 Idea 2017.1 tomcat 8.5.21 JDK 1.8 reporting information 30-Jul-2018 16:18:27.474 [RMI TCP Connection(2)-127.0.0.1]...
city id name 1 Beijing 2 Shanghai 3 Tianjin news Newslist id name city 1 my 1 2 my 2 3 my 2 4 my 3 find out how many messages are there in Beijing how many messages are there in Shanghai how many messages are there in Tianjin ...
[solution] add to the front-end code as prompted by Derek_Chen <meta charset="gbk"> The display is normal after ! < hr > [problems encountered] attempted to receive the uploaded file using PHP, and the file was received succes...