随笔分类 -  vue

摘要:在webstorm上配置Less 首先,全局安装less 然后,在webstorm上配置less插件,"File" --> "settings"-->"Tools" 在"file Watchers" -->"+"-->"Less" 在"Program"里填写less的安装路径; 在"Argument 阅读全文
posted @ 2017-04-27 17:11 黄鹂 阅读(1627) 评论(0) 推荐(0)
摘要:入门地址: http://mint-ui.github.io/#!/zh-cn 下载依赖cd到项目目录下, 下载我们用的UI框架: 分为全局引入和按需引入 全局引入: npm install mint-ui -S 下载依赖 在man.js中引入 import Mint from 'mint-ui'; 阅读全文
posted @ 2017-04-24 22:06 黄鹂 阅读(2635) 评论(0) 推荐(0)
摘要:原先的: http://xxx.xx.xxx.xxx:xxx/#/ 现在的: http://xxx.xx.xxx.xxx:xxx/guangfu/#/ 阅读全文
posted @ 2017-04-21 17:49 黄鹂 阅读(3843) 评论(0) 推荐(0)
摘要:解决方式: 添加了type类型。 阅读全文
posted @ 2017-04-21 17:44 黄鹂 阅读(10213) 评论(0) 推荐(0)
摘要:简写 带类型 带多种检查 所以, 当你获取不到props的值的时候,可以先仔细检查拼写是否正确。 传值与传字面量 在vue的组件中传递数据,如果是单纯传递字面量,如 那么在hello中获取的props result的值就是“success”,如果希望进行值传递,需要在指令前加 ':' 冒号,这样,父 阅读全文
posted @ 2017-04-20 23:36 黄鹂 阅读(2295) 评论(0) 推荐(1)
摘要:Vue.js 提供了一个方法 watch,它用于观察Vue实例上的数据变动。对应一个对象,键是观察表达式,值是对应回调。值也可以是方法名,或者是对象,包含选项。 在实例化时为每个键调用 $watch() ; 阅读全文
posted @ 2017-04-20 23:29 黄鹂 阅读(5128) 评论(0) 推荐(0)
摘要:在css样式表里面加入一个背景样式background:#FFFFFF ! important 阅读全文
posted @ 2017-03-30 13:01 黄鹂 阅读(3560) 评论(0) 推荐(0)
摘要:运行后,在用户名输入,console界面中弹出警告: Avoid mutating a prop directly since the value will be overwritten whenever the parent component re-renders. Instead, use a 阅读全文
posted @ 2017-03-28 13:20 黄鹂 阅读(20728) 评论(0) 推荐(1)
摘要:1 router.beforeEach((to, from, next) => { 2 // alert(sessionStorage.getItem('accessToken')) 3 // console.log(to); 4 if ((to.path!='/login')&&(!sessionStorage.getItem('accessToken')... 阅读全文
posted @ 2017-03-27 21:14 黄鹂 阅读(3224) 评论(0) 推荐(0)
摘要:第一、加载的顺序,应该先加载下拉框要选择的数据,然后在通过编辑查询数据后回显。 第二、要保证select下拉的ID和v-model里边的id保持一致。 第三、elementUI就会自动的将数据回显了。 一下是截图: 阅读全文
posted @ 2017-03-23 22:04 黄鹂 阅读(48340) 评论(0) 推荐(0)
摘要:1 const routes = [ 2 { 3 path: '/', 4 component: App, 5 children: [ 6 {path: '/index/:type', name: 'index', component: Index}, 7 {path: '/home', name: 'home', compone... 阅读全文
posted @ 2017-03-22 00:14 黄鹂 阅读(245) 评论(0) 推荐(0)
摘要:1 import fn from 'fn' 2 Vue.prototype.fn = fn; 3 4 调用的时候 5 6 this.fn.way 阅读全文
posted @ 2017-03-21 22:05 黄鹂 阅读(362) 评论(0) 推荐(0)
摘要:1 前言 2 3 在使用vue一个多礼拜后,感觉现在还停留在初级阶段,虽然知道怎么和后端做数据交互,但是对于mounted这个挂载还不是很清楚的。放大之,对vue的生命周期不甚了解。只知道简单的使用,而不知道为什么,这对后面的踩坑是相当不利的。 4 5 因为我们有时候会在几个钩子函数里做一些事情,什么时候做,在哪个函数里做,我们不清楚。 6 7 于是我开始先去搜... 阅读全文
posted @ 2017-03-20 23:53 黄鹂 阅读(269) 评论(0) 推荐(0)
摘要:关键部分的截图 阅读全文
posted @ 2017-03-17 23:51 黄鹂 阅读(1549) 评论(0) 推荐(0)
摘要:两者切换,动态显示对应的列表详情。 通过v-show的判断 数据驱动 阅读全文
posted @ 2017-03-16 22:53 黄鹂 阅读(1021) 评论(0) 推荐(0)
摘要:1 { 2 path: '/Tree', 3 component: Tree, 4 children: [ 5 { 6 path: '/', 7 component: Come 8 ... 阅读全文
posted @ 2017-03-16 22:47 黄鹂 阅读(258) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2017-03-16 22:32 黄鹂 阅读(223) 评论(0) 推荐(0)
摘要:主要是这部分,功能实现了圆角,阴影的效果, 注释的部分也可以实现圆角效果。 阅读全文
posted @ 2017-03-15 22:19 黄鹂 阅读(808) 评论(0) 推荐(0)
摘要:先进行安装echarts, 然后在根据echarts官网的提示例子,进行开发练手, 最后就是配置一下路由,进行页面的跳转。 更多更好的效果,可以再echarts官网查看。 阅读全文
posted @ 2017-03-15 21:57 黄鹂 阅读(1441) 评论(0) 推荐(0)
摘要:1 // 第一种 2 { 3 path:'/', 4 component: require('../components/Login.vue') 5 }, 6 7 8 // 第二种 9 { path: '/', redirect: '/wordcloud' }, 10 { path: '/wordcloud', compo... 阅读全文
posted @ 2017-03-15 20:39 黄鹂 阅读(2742) 评论(0) 推荐(0)