在这里,我怀疑'DELETE_NOTE‘的逻辑语句。note.id将保存id号0,1,2...我的疑问是action.payload对这种情况做了什么。它会保存id为1,2,3的数字吗?请清除它。export default function reducer(state, action) { case 'SET_CURRENT_NOTE':
我使用的是React-Context-API而不是redux,但是在创建了StateProvider和reducer之后,当我将应用程序组件包装在Index.js中的StateProvider中时。Index.js import React from "react";import "./reducer";
Rea
存在库,构建在bundle.js中,驻留在npm存储库中,包含一些逻辑,还存在导入此库的父应用程序(类似meta)。现在,有一些代码:import reducer from './reducers'
import Home from ".react-hot-loader */ "../../node_modules/react-hot-loader/index.js<