摘要:
一、axios基本属性和设置 axios文档 安装 1 npm i -S axios axios支持的请求方式 get post put:修改数据 delete:删除数据 axios响应结果的属性 config:配置信息 data:实际响应的数据 headers:响应头信息 status:响应状态码 阅读全文
posted @ 2021-07-12 15:28
大米饭盖饭
阅读(89)
评论(0)
推荐(0)
摘要:
一、使用步骤 安装脚手架 1 npm i -g create-react-app 创建项目 1 create-react-app 项目名称 1 #也可以不用安装create-react-app创建项目 2 npx create-react-app my-app 清理创建好的项目中不需要的文件及文件夹 阅读全文
posted @ 2021-07-12 14:40
大米饭盖饭
阅读(95)
评论(0)
推荐(0)
摘要:
一、说明 下面代码运行后会报错,因为在React中并不存在类似于Vue的双向数据绑定操作 1 import React, { Component } from "react"; 2 3 class App extends Component { 4 state = { 5 msg: "hello w 阅读全文
posted @ 2021-07-12 13:02
大米饭盖饭
阅读(137)
评论(0)
推荐(0)