会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
jia-zq
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
7
下一页
2023年5月15日
vue报错EISDIR: illegal operation on a directory, read解决
摘要: 报错: EISDIR: illegal operation on a directory, read Internal server error: EISDIR: illegal operation on a directory, read 原因:引入子组件时,子组件是xxx/文件夹名/index.
阅读全文
posted @ 2023-05-15 19:00 jiazq
阅读(8012)
评论(1)
推荐(2)
2023年5月10日
子组件中直接修改父组件传过来的值
摘要: 父组件使用v-model绑定 child.vue export default { props: { value: { type: String, default: '' }, }, model: { prop: 'value', event: 'change' } methods: { // va
阅读全文
posted @ 2023-05-10 20:09 jiazq
阅读(140)
评论(0)
推荐(0)
ie width: fit-content、max-content不适配
摘要: 在ie下,设置width: max-content、fit-content不适配 width: max-content;改为: width: auto; white-space: nowrap; width: fit-content修改父元素display: flex,然后改为width: auto
阅读全文
posted @ 2023-05-10 19:55 jiazq
阅读(192)
评论(0)
推荐(0)
2023年3月6日
JS dom元素滚动到顶部
摘要: 设置dom元素的scrollTop属性为0 直接设(可能存在闪动,看需求): document.querySelector('.xxx').scrollTop = 0 动画平滑滚动: toTop () { let timer = null timer = requestAnimationFrame(
阅读全文
posted @ 2023-03-06 19:57 jiazq
阅读(593)
评论(0)
推荐(0)
2023年3月1日
JS 关闭子页面,刷新父页面
摘要: /** * 关闭子页面 * @param {*} reflash 是否刷新父页面 */ export function closeChildPage(reflash) { if (reflash) window.opener.parent.location.reload() // 刷新父页面 win
阅读全文
posted @ 2023-03-01 20:19 jiazq
阅读(16)
评论(0)
推荐(0)
2023年2月27日
JS 时间比较,判断截止时间
摘要: /** * 截至日期格式示例:2022-06-02 15:00:00 * true:到了截止时间,false:未到截止时间 */ export function getDeadline(str) { const myDate = new Date() const year = myDate.getF
阅读全文
posted @ 2023-02-27 19:32 jiazq
阅读(118)
评论(0)
推荐(0)
2022年12月21日
vue-router3,点击相同的路由,会报错NavigationDuplicated
摘要: vue-router点击相同的路由链接会报错NavigationDuplicated { "_name": "NavigationDuplicated", "name": "NavigationDuplicated", "message": "Navigating to current locati
阅读全文
posted @ 2022-12-21 19:35 jiazq
阅读(113)
评论(0)
推荐(0)
2022年12月7日
H5 英文字母连续过长导致不换行,超过屏幕宽度
摘要: 需要在对应元素的css样式中添加 word-break: break-all; word-wrap: break-word;
阅读全文
posted @ 2022-12-07 19:57 jiazq
阅读(130)
评论(0)
推荐(0)
2022年11月8日
scroll事件监听不生效
摘要: vue使用window.addEventListener('scroll', this.scroll)监听滚动事件不生效 window.addEventListener('scroll', this.scroll) 写在mounted里面 html,body的高度别限制, 如height: 100%
阅读全文
posted @ 2022-11-08 18:55 jiazq
阅读(662)
评论(0)
推荐(0)
2022年11月4日
vue路由跳转打开新的页面
摘要: const router = this.$router.resolve({ path: '/path' }) window.open(router.href, '_blank')
阅读全文
posted @ 2022-11-04 20:00 jiazq
阅读(58)
评论(0)
推荐(0)
上一页
1
2
3
4
5
6
7
下一页
公告