摘要: 安装插件 yarn add multer 在serve 根路径建个uploads文件夹 接下来代码 上面引入 const multer = require("multer"); const path = require("path"); let files = []; const storage = 阅读全文
posted @ 2021-12-23 20:36 小李的博世界 阅读(199) 评论(0) 推荐(0) 编辑
摘要: react 实现tab切换 三角形筛选样式 ​ ​ 这次使用的是react的class 类组件 import React, { Component } from 'react' import { LeftOutline, SearchOutline } from 'antd-mobile-icons' import { NavLink } f 阅读全文
posted @ 2021-12-23 20:25 小李的博世界 阅读(114) 评论(0) 推荐(0) 编辑
摘要: 注意代码要放在首页里 //方法一 var is_mobi = navigator.userAgent.toLowerCase().match(/(ipod|iphone|android|coolpad|mmp|smartphone|midp|wap|xoom|symbian|j2me|blackbe 阅读全文
posted @ 2021-08-09 09:54 小李的博世界 阅读(69) 评论(0) 推荐(0) 编辑
摘要: 第一种方法如果没有高度是有问题,基本不算一种方式 <div className="mxbox"> <div className="mbox1"> position:absolute<br/> left top<br/> right bottom 0<br/> margin auto<br/> </d 阅读全文
posted @ 2021-07-14 20:02 小李的博世界 阅读(95) 评论(0) 推荐(0) 编辑
摘要: 一对一一边写html 一边写css一小块为单位html csscss html整块单位html csscss html react/first-react/src/views/Wk/index.jsx import React, { Component } from 'react'; class V 阅读全文
posted @ 2021-07-14 20:00 小李的博世界 阅读(81) 评论(0) 推荐(0) 编辑
摘要: 布局方式,两列三列布局中间自适应 <!DOCTYPE html> <html> <head> <meta charset="utf-8"/> <title>web前端</title> <meta name="description" content="web前端" /> <meta name="ke 阅读全文
posted @ 2021-07-14 19:59 小李的博世界 阅读(38) 评论(0) 推荐(0) 编辑
摘要: 第一步,安装 sinopia npm install -g sinopia 开启终端一: 第二步,启动 sinopia -l 127.0.0.1:4873 开启终端二: cd 到某个指定仓库 mkdir unit-restful-axios(包的名称) cd unit-restful-axios n 阅读全文
posted @ 2021-07-14 19:58 小李的博世界 阅读(392) 评论(0) 推荐(0) 编辑
摘要: 1、axios post通过点击事件提交数据不需要使用input直接使用state2、pdd你好天天象上默认执行点击(1,2,3)也可以执行并且能切换页码3、tab 针对新闻不同时4、天天象上首页和精品微课右侧 鼠标滑过展示全内容 代码如下: react/first-react/src/views/ 阅读全文
posted @ 2021-07-14 19:57 小李的博世界 阅读(205) 评论(0) 推荐(0) 编辑
摘要: 见代码 class View extends Component { constructor(props){ super(props); this.state = { cancel:null, cancel2:null } } //简易版 async getApi2(url,cfg,headers) 阅读全文
posted @ 2021-07-14 19:55 小李的博世界 阅读(482) 评论(0) 推荐(0) 编辑
摘要: BetterScroll 是什么 BetterScroll 是一款重点解决移动端(已支持 PC)各种滚动场景需求的插件。它的核心是借鉴的 iscroll (opens new window) 的实现,它的 API 设计基本兼容 iscroll,在 iscroll 的基础上又扩展了一些 feature 阅读全文
posted @ 2021-07-12 16:50 小李的博世界 阅读(148) 评论(0) 推荐(0) 编辑