08 2022 档案

CSS选择器
摘要:CSS 选择器参考手册 :CSS 元素选择器 容易混淆 后代选择器 <style type="text/css"> h1 em {color:red;} </style> <h1>This is a <em>本处变红</em> heading</h1> 子元素选择器 <style type="tex 阅读全文

posted @ 2022-08-20 11:25 anjun_xf 阅读(23) 评论(0) 推荐(0) 编辑

a菜单点击标红,其他标黑代码
摘要:<script> let aList = document.querySelectorAll('a'); console.log(aList); for (let index = 0; index < aList.length; index++) { const element = aList[in 阅读全文

posted @ 2022-08-17 14:16 anjun_xf 阅读(22) 评论(0) 推荐(0) 编辑

axios下载指定文件
摘要:let url='http://192.18.0.12/a/123.xls' axios.get( url, { params: data, responseType: 'blob' } ).then(res => { this.loading = false; const content = re 阅读全文

posted @ 2022-08-17 09:34 anjun_xf 阅读(249) 评论(0) 推荐(0) 编辑

元素设置背景图片
摘要:背景图片 background属性 background-color 背景颜色 background-image: url('i3.png') 图片 background-size 图片大小 background-repeat 平铺方式 background-position 图片位置 例子 /*图 阅读全文

posted @ 2022-08-15 15:07 anjun_xf 阅读(29) 评论(0) 推荐(0) 编辑

什么是闭包?
摘要:什么是闭包? 一天老板要求小李,实现一个函数,每执行一次输出就累计减1。 小李第一天完成任务后给老板看。 老板立刻说:全局变量a任意函数都可使用到,会污染环境。 于是就有了第二天写法。闭包里变量可避免变量污染。 闭包满足4个条件: 1、有函数嵌套 2、内部函数引用外部函数变量 3、返回值是函数 4、 阅读全文

posted @ 2022-08-07 16:27 anjun_xf 阅读(20) 评论(0) 推荐(0) 编辑

导航

TOP
点击右上角即可分享
微信分享提示