自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(6)
  • 收藏
  • 关注

原创 dva数据流

import { Effect, ImmerReducer } from 'umi'import { login } from '@/services/admin' // *******************export interface ILoginState { adminname: string token: string role: number}export interface ILoginModelInterface { namespace: 'admin' //.

2021-07-25 18:01:29 204

原创 封装小程序不支持promise的请求

// 小程序提供了数据请求的方案// https://developers.weixin.qq.com/miniprogram/dev/api/network/request/wx.request.htmlconst baseURL = 'http://121.89.205.189/api'// 小程序要求请求的地址必须是 https协议的,还必须是备案过的域名// 如果你的小程序的接口不满足,开发阶段可以 绕过这个限制,但是上线时必须满足条件// 编辑器的右上角 -- 详情 --本地设置 -.

2021-07-14 13:40:12 324

原创 上传图片代码

<input type="file" ref={fileRef} multiple onChange={()=>{ const file = fileRef.current.files[0] console.log(imgRef.current); const img = imgRef.current const reader = new FileReader() reader.readAsDataURL(file.

2021-07-11 08:25:47 85

原创 简单上传图片

<input ref = {fileRef} type="file" multiple onChange = {() => { const file = fileRef.current.files[0] const img = imgRef.current const reader = new FileReader() reader.readAsDataURL(file) reader.onload = funct...

2021-07-09 08:26:50 84

原创 vue里使用滚轮事件

mounted(){ window.addEventListener('scroll',this.handleScroll)},methods:{handleScroll(){ let scrollTop = window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop // 滚动条偏移量 let offsetTop = document.querySelector('.b.

2021-07-02 11:57:49 248

原创 封装axios

import axios from 'axios'// 开发环境 cnpm run start development// 生产环境 cnpm run build production// 判断环境const isDev = process.env.NODE_ENV === 'development'const ins = axios.create({ // baseURL: isDev ? 'http://localhost:3001/api' : 'http://www.wu.

2021-06-28 20:26:23 41

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除