electron-vue中使用iview 报错this. is readonly的解决办法
title: electron-vue中使用iview 报错this. is readonly的解决办法
toc: false
date: 2019-02-12 19:33:28
categories:
- Web
tags:
- vue
- iview
报大段xxx is readonly的解决办法
修改.electron-vue文件夹中的webpack.renderer.config.js内第22行的
let whiteListedModules = ['vue']
为:
let whiteListedModules = ['vue', 'iview']
即可。
原理:
.electron-vue/webpack.renderer.config.js
Targets electron's renderer process. This configuration handles your Vue application, so it includes vue-loader and many other configurations that are available in the official vuejs-templates/webpack boilerplate.
White-listing Externals
One important thing to consider about this config is that you can whitelist specific modules to not treat as webpack externals. There aren't many use cases where this functionality is needed, but for the case of Vue UI libraries that provide raw *.vue components they will need to be whitelisted, so vue-loader is able to compile them. Another use case would be using webpack aliases, such as setting vue to import the full Compiler + Runtime build. Because of this, vue is already in the whitelist.
参考链接: https://github.com/iview/iview/issues/2513
electron-vue中使用iview 报错this. is readonly的解决办法的更多相关文章
- vue中使用JSX报错,如何解决
Support for the experimental syntax 'jsx' isn't currently enabled (32:12): 30 | }, 31 | render() { & ...
- Intellij里检出svn报错找不到svn解决办法
Intellij里检出svn报错找不到,解决办法: 1. 安装svn客户端: 2. 去掉settings->version control->subversion里的use command ...
- 在vue中使用echarts报错Cannot read property getAttribute of null
报错信息如下: 报错代码: mounted() { // ... this.drwaCharts() // drawCharts方法为自己定义的包含渲染 echarts 图表的方法 // ...} 之 ...
- vue中npm install 报错之一
报错原因: 这是因为文件phantomjs-2.1.1-windows.zip过大,网络不好,容易下载失败 PhantomJS not found on PATH 解决方案一: 选择用cnpm ins ...
- jupyter notebook中出现ValueError: signal only works in main thread 报错 即 长时间in[*] 解决办法
我在jupyter notebook中新建了一个基于py3.6的kernel用来进行tensorflow学习 但是在jupyter notebook中建立该kernel时,右上角总是显示 服务正在启动 ...
- 关于Drupal中使用hook_schema建立数据库报错PDOException: SQLSTATE[42000]的解决办法
报错信息如下:PDOException: SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too l ...
- eclips 中的 svn 更新报错,被锁住解决办法
svn更新不下来,在文件的目录上选择 Team,然后选择 Refresh/Cleanup ,然后就可以了,这个方法我自己试有效,做为参考,对其它情况不一定有效 报错如下 解决方法
- http://localhost/ 或 http://127.0.0.1/ 报错:HTTP 404 的解决办法
一些初次接触使用 Eclipse 工具来开发 JAVA Web 工程的开发人员,可能会对 Eclipse 和 Tomcat 的绑定产生一个疑惑. 那就是 在修改了 Tomcat 的8080端口为80后 ...
- GIT 报错:Result too large 解决办法
在使用bower install命令下载前端依赖的js插件时,git出错了,报错信息如下: bower ECMDERR Failed to execute "git ls-remote -- ...
随机推荐
- 什么是 HTML5?
HTML5 是下一代的 HTML. 什么是 HTML5? HTML5 将成为 HTML.XHTML 以及 HTML DOM 的新标准. HTML 的上一个版本诞生于 1999 年.自从那以后,Web ...
- readonly and const variable
共同点:都是常量: 不同点:const的值必须在编译前确定,通常在声明的同时赋值:而readonly可在运行时确定:
- vue-留言板-bootstrap
最近看完入门API,看完视频自己写了个留言板,因为主要是学习vue,所以就复习了一下bootstrap,布局更简单,先看看样式吧. 简单清晰的布局,先说一下功能, 1.输入用户名密码点击提交放入表格 ...
- Win8.1应用开发之适配器模式(C#实现)
实际上适配器模式是用于解耦.设想一下我们的程序模块A在与模块B打交道时,需要在许多地方多次使用B中某个类的方法,而负责开发B的程序猿Tom还未完全实现该类,会随时更改该类中的方法,那么当Tom在修改时 ...
- jQuery中Ajax的几种写法
1. $.post(url,params,callback); 采用post方式提交,中文参数无需转码,在callback中如果要获取json字符串,还需转换一下. 2. $.getJSON(u ...
- K8s的工作原理
title: Kubernetes之初探 subtitle: K8s的工作原理 date: 2018-09-18 18:26:37 --- K8s概述 我清晰地记得曾经读到过的一篇博文,上面是这样写的 ...
- JsonNetResult
public class JsonNetResult : JsonResult { public JsonNetResult() { Settings = new JsonSerializerSett ...
- php程序员需要撑握的知识点
1. 基本知识点 HTTP协议中几个状态码的含义:1xx(临时响应) 表示临时响应并需要请求者继续执行操作的状态代码. 代码 说明 100 (继续) 请求者应当继续提出请求. 服务器返回此代码 ...
- 洛谷P1425 小鱼的游泳时间
题目描述 伦敦奥运会要到了,小鱼在拼命练习游泳准备参加游泳比赛,可怜的小鱼并不知道鱼类是不能参加人类的奥运会的.这一天,小鱼给自己的游泳时间做了精确的计时(本题中的计时都按24小时制计算),它发现自己 ...
- django rest-farme-work 的使用(3)
请求和响应 Requests and Responses 从这一片来说,我们将真正开始覆盖REST框架的核心.我们来介绍一些基本的构建块 Request objects REST框架引入了一个Requ ...