随笔分类 -  我的笔记---vue

摘要:最近在做管理后台,vue2.0基于elementui框架进行开发。elementui的api中表单验证都是单个vue文件的验证。而我的保存按钮放在了父组件了,验证对象为三个子组件我的灵机一动 想到了解决方法 哈哈哈1.在三个子组件分别写一个方法用于验证当前表单 incrementTotal(){ let formName="personSetting" t... 阅读全文
posted @ 2017-10-25 14:55 月月木有小情绪 阅读(5217) 评论(1) 推荐(0)
摘要:swiper.vue 子组件 info.vue 父组件 <template> <div> <swiper :sildeArr="img" :autoPlaytime="time" unActive="#888" active="#fff" ></swiper> </div></template><s 阅读全文
posted @ 2017-08-23 17:41 月月木有小情绪 阅读(338) 评论(0) 推荐(0)
摘要:移动端web开发常见问题 常见问题1、移动端如何定义字体font-family三大手机系统的字体:ios 系统默认中文字体是Heiti SC默认英文字体是Helvetica默认数字字体是HelveticaNeue无微软雅黑字体android 系统默认中文字体是Droidsansfallback默认英 阅读全文
posted @ 2017-05-05 15:56 月月木有小情绪 阅读(268) 评论(0) 推荐(0)
摘要:export default new Router({ linkActiveClass: 'active', routes: [ { path: '/hello', name: 'Hello', component: Hello }, { path: '... 阅读全文
posted @ 2017-04-20 14:28 月月木有小情绪 阅读(162) 评论(0) 推荐(0)
摘要:<!-- vuex 配置js store.js -->1.引入vue和vuex import Vue from 'vue'import Vuex from 'vuex'Vue.use(Vuex);const store= new Vuex.Store({<!-- 用来放数据 --> state:{ 阅读全文
posted @ 2017-03-14 16:52 月月木有小情绪 阅读(260) 评论(0) 推荐(0)
摘要:ps:App.vue 父组件 Hello.vue 子组件 App.vue : 阅读全文
posted @ 2017-02-07 16:07 月月木有小情绪 阅读(13835) 评论(4) 推荐(0)
摘要:ps:App.vue 父组件 Hello.vue 子组件 阅读全文
posted @ 2017-02-07 16:04 月月木有小情绪 阅读(21647) 评论(4) 推荐(3)
摘要:全局安装vue-cli,使用命令npm install -g vue-cli。 下载模板代码,使用命令vue init webpack my-project,之后会有一些询问,按需填写即可。 最后会看到生成了一个叫my-project的文件夹,里面就是vue-cli脚手架搭建出来的目录。 这时要进入 阅读全文
posted @ 2017-02-07 15:28 月月木有小情绪 阅读(291) 评论(0) 推荐(0)