摘要:在自己的项目中新建一个index.js做打包组件的配置 1 import 组件的名字 from "组件的地址"; 2 const comArr = [组件的名字]; 3 export default { 4 install(Vue) { // install是vue中的方法,此方法要在export
阅读全文
摘要:问题截图 element中:中的popper-append-to-body(已经默认是true)一般不会出现 antd中:getPopupContainer={()=>document.getElementById('Select')} 或直接使用getPopupContainer属性的,可以直接使
阅读全文
摘要:Vue项目网页报错Cannot read property ‘components‘ of undefined 记录一下项目中出现的这个报错,这个报错的原因是在App.vue中导入的组件中重复引用了同一个文件的mixin下的文件
阅读全文
摘要:下载展示框架vue-pdf-signature执行命令 npm install vue-pdf-signature -save 在组件中引入 import pdf from 'vue-pdf-signature'; import CMapReaderFactory from 'vue-pdf-sig
阅读全文
摘要:是因为npm版本太高了 运行 npm i npm@6 -g就可以了
阅读全文
摘要:1 引入第三方文件 import router from './router'; 使用 this.router; 2 引入模块,字符串,数值,函数,类获取按需导入 import { testFun,string,number,class} from '../js/test.js'; 使用testFu
阅读全文
摘要:简介: 将单个文件或整个目录复制到构建目录 描述: 打包或使用与static同级的文件或文件夹,就需要在CopyWebpackPlugin方法中配置,这样才能访问到此文件,不然会报找不到 实例: 1 // 复制到自定义静态源 2 new CopyWebpackPlugin([ 3 { 4 // 来自
阅读全文
摘要:Vue中跳转页面的方式 1、<router-link>组件 例子: // 单纯的跳转页面 <router-link to="home">Home</router-link>或<router-link :to="{ path: 'home' }">Home</router-link> 相当于 <a h
阅读全文