使用Vue CLI 3 的 vue create 创建vue+ts 项目,使用默认配置, 控制台报警告Calls to 'console.log' are not allowed,解决

在tslint.json中的rules下 添加: "no-console": false。无需向在tsling.config中添加"extends":"./tslint.config"。重启服务,搞定。

附tslint.json文件:

 
{
"defaultSeverity": "warning",
"extends": [
"tslint:recommended"
],
"linterOptions": {
"exclude": [
"node_modules/**"
]
},
"rules": {
"quotemark": [true, "single"],
"indent": [true, "spaces", 2],
"interface-name": false,
"ordered-imports": false,
"object-literal-sort-keys": false,
"no-consecutive-blank-lines": false,
"max-line-length": [ false ],
"no-console": false
}
}

vue tslint报错: Calls to 'console.log' are not allowed的更多相关文章

  1. Vue.js报错Failed to resolve filter问题原因

    Vue.js报错Failed to resolve filter问题原因 金刚 vue Vue.js js javascript 之前使用vue.js写分页功能时,写了一个过滤器,发现一个比较奇怪的错 ...

  2. Vue的报错:Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>'

    Vue的报错:Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>' ...

  3. vue IE 报错 引用babel-polyfill

    一.vue 项目报错 vuex requires a Promise polyfill in this browser     在网上找到下面三篇文章,然而和我的项目都不太一样. 我的项目基于 基础模 ...

  4. mysql报错Ignoring the redo log due to missing MLOG_CHECKPOINT between

    mysql报错Ignoring the redo log due to missing MLOG_CHECKPOINT between mysql版本:5.7.19 系统版本:centos7.3 由于 ...

  5. 【转】Vue项目报错:Uncaught SyntaxError: Unexpected token <

    这篇文章主要介绍了Vue项目报错:Uncaught SyntaxError: Unexpected token <,在引入第三方依赖的 JS 文件时,遇到的一个问题,小编觉得挺不错的,现在分享给 ...

  6. vue 项目报错,提示:Cannot read property '$createElement' of undefined at render ...

    vue 项目报错,提示:Cannot read property '$createElement' of undefined at render ...

  7. Vue. 之 报错 Uncaught (in promise)

    Vue. 之 报错 Uncaught (in promise) 在点击同一个URL的时候,会报错如下: 解决方案: 在项目目录下运行 npm i vue-router@3.0 -S 即可.

  8. @vue/cli3中解决Elint中console.log报错的问题

    方法一:package.json中”eslintConfig”>"rules”字段添加如下代码 "no-console": "off", &qu ...

  9. 在package.json中配置Script执行npm run tslint报错问题

    今天在学习tslint的时候,按照git clone下angular2-webpack-starter的代码执行npm run lint时,虽然代码进行了检测,但检测完成后npm始终报错, //pac ...

随机推荐

  1. mui弹出二维码示例

    <div id="tap_popover" class="box mui-popover mui-popover-action mui-popover-bottom ...

  2. 在CentOS下搭建GoLang开发环境

    下载安装包 [vagrant@dk ~]$ wget http://mirrors.ustc.edu.cn/golang/go1.13.linux-amd64.tar.gz 使用USTC 中科大开源镜 ...

  3. 从零开始学Flask框架-005

    表单 Flask-WTF 项目结构 pip install flask-wtf 为了实现CSRF 保护,Flask-WTF 需要程序设置一个密钥.Flask-WTF 使用这个密钥生成加密令牌,再用令牌 ...

  4. ASP.NET Core依赖注入多个服务实现类

    依赖注入在 ASP.NET Core 中起中很重要的作用,也是一种高大上的编程思想,它的总体原则就是:俺要啥,你就给俺送啥过来. 服务类型的实例转由容器自动管理,无需我们在代码中显式处理. 因此,有了 ...

  5. python装饰器无参及有参案例

    装饰器无参和有参案例:

  6. Codeforces Round #421 (Div. 1) (BC)

    1. 819B Mister B and PR Shifts 大意: 给定排列$p$, 定义排列$p$的特征值为$\sum |p_i-i|$, 可以循环右移任意位, 求最小特征值和对应移动次数. 右移 ...

  7. Mock常用占位符一览

    1.随机字符串(类型 , 位数)@string(lower,10) lower : 小写字母upper : 大写字母number : 数字 2.随机int(下限 , 上限)@integer(60, 1 ...

  8. 面试必问:Golang高阶-Golang协程实现原理

    引言 实现并发编程有进程,线程,IO多路复用的方式.(并发和并行我们这里不区分,如果CPU是多核的,可能在多个核同时进行,我们叫并行,如果是单核,需要排队切换,我们叫并发) 进程和线程的区别 进程是计 ...

  9. Spring AOP 多个切点实现:JdkDynamicAopProxy

    Spring Aop 的底层生成代理类i的实现除 jdk的动态代理技术外,还用到了Cglib,不过在封装两者的设计原理上相差不大,只是底层工具不同而已. 本文只分析JdkDynamicAopProxy ...

  10. CentOS 6.5 iptables原理详解以及功能说明

    CentOS 6.5 iptables原理详解以及功能说明 来源 https://blog.51cto.com/tanxw/1389114 前言 iptables其实就是Linux下的一个开源的信息过 ...