上一页 1 2 3 4 5 6 7 8 9 ··· 18 下一页
摘要: //方式1:const copyText = (text, callback) => { // text: 要复制的内容, callback: 回调 var tag = document.createElement('input'); tag.setAttribute('id', 'copy_inp 阅读全文
posted @ 2022-01-04 16:20 Action_swt 阅读(169) 评论(0) 推荐(0) 编辑
摘要: !(function (doc, win) { // 拿到html标签的dom元素对象 var docEle = doc.documentElement, evt = "onorientationchange" in window ? "orientationchange" : "resize", 阅读全文
posted @ 2021-12-21 19:19 Action_swt 阅读(259) 评论(0) 推荐(0) 编辑
摘要: 1、import导入 import tx from "@a/images/tx.jpeg" 2、require加载加.defalut <img src={require('../../assets/images/zplogo.png').default} alt=""/> 阅读全文
posted @ 2021-11-25 10:04 Action_swt 阅读(125) 评论(0) 推荐(0) 编辑
摘要: 1、修改table表头: div .ant-table-thead > tr > th{ background: #EEF4FE; text-align: center; border-right: 0px !important; font-size:14px; font-weight: 400; 阅读全文
posted @ 2021-11-12 10:23 Action_swt 阅读(30) 评论(0) 推荐(0) 编辑
摘要: history路由(pathname)或者hash路由 (hash) 阅读全文
posted @ 2021-10-21 15:52 Action_swt 阅读(1859) 评论(0) 推荐(0) 编辑
摘要: 找到node_modules 里面找到 react-loadable 包 componentWillMount 修改为 UNSAFE_componentWillMount 即可。 阅读全文
posted @ 2021-10-21 15:36 Action_swt 阅读(1283) 评论(0) 推荐(0) 编辑
摘要: 由于用的是axios封装的。 没有指定 axios.defaults.baseURL 阅读全文
posted @ 2021-07-28 18:35 Action_swt 阅读(396) 评论(0) 推荐(0) 编辑
摘要: react的特点: 1、组件化,模块化,虚拟DOM,diff算法。 2、声明式的框架,可追踪性更强。 3、react 只关注视图层 & react 是MVC架构。react可以是这两种,但是react可以的更多。 4、react的灵活、以及react带来的思维模型、直观的API。 5、react将组 阅读全文
posted @ 2021-07-23 17:35 Action_swt 阅读(626) 评论(0) 推荐(0) 编辑
摘要: $.validator.addMethod("xssCheck",function(value,element){ // var strExp=/.*<(script|a|img|link|style|iframe|frame|onerror|body|document)>.*|.*(\'|\"). 阅读全文
posted @ 2021-07-22 14:55 Action_swt 阅读(351) 评论(0) 推荐(0) 编辑
摘要: 受控组件:输入的值始终受 React 的 state 驱动。 非受控组件:数据现用现取。 react推荐使用受控组件。 高阶函数(增强函数的作用): 1、函数参数为函数。 2、函数返回一个函数。 阅读全文
posted @ 2021-06-28 16:25 Action_swt 阅读(61) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 18 下一页