
vue
VirtuousIntro
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
vue实现跑马灯的效果
div.test1(ref="test1") p.test(ref="test") 跑马灯,跑起来,嗨起来~~hello world 你好世界 世界你好哇test () { let boxWidth = this.$refs.test1.offsetWidth let testWidth = this.$refs.test.scrollWidth if (testWidth > boxWidth) { this.testTimer = setInterval(() =.原创 2022-05-11 17:31:02 · 1301 阅读 · 0 评论 -
vue控制列表的字数限制
<template lang="pug"> div.radar ul.radar__list li.radar__item(v-for="item in controlTextList" :id="item.id") img.img(:src="item.imgSrc") div.item ...原创 2019-06-25 16:07:11 · 2212 阅读 · 1 评论 -
vuejs实现图片放大镜效果
原作者地址:https://github.com/lemontree2000/vue-magnify转载优化作者地址:https://segmentfault.com/a/1190000012260414// 组件<template> <div class="magnify"> <div class="preview-box" @mous...转载 2019-06-25 11:59:24 · 2817 阅读 · 3 评论 -
vue.js怎么动态的添加class名称以及判断只给对应的一个添加
{active:index==dynamic}">{{index}}{{listRenderingList.text}}var listRenderingVm=new Vue({el:'#listRendering',data:{listRenderingLists:[{text:'Foo'},{text:'Bar'},{text:'Foo Bar'原创 2018-01-09 15:34:52 · 15592 阅读 · 0 评论 -
vue简单的if条件渲染和for循环
*{margin: 0;padding: 0;}body{font-family: "microsoft yahei","arial";font-size: 14px;margin: 5px 10px;line-height: 30px;}ul{list-style: none;}div{border-bottom: 1px solid #999;}原创 2018-01-09 14:10:16 · 4149 阅读 · 0 评论 -
vue的显示与隐藏
> html> head> meta charset="utf-8"> title>vue点击切换显示隐藏title> script src="https://cdn.bootcss.com/vue/2.2.2/vue.min.js">script> head> body> div id="example">转载 2018-01-08 10:31:58 · 8783 阅读 · 0 评论 -
vue简单的添加与删除
添加Vue.component('todo-item', {template: '{{ title }}X', props: ['title']});var exampleVm=new Vue({ el: '#todo-list-example', data: { newTodoText: '', todos: [//原创 2018-01-12 09:20:21 · 2039 阅读 · 0 评论