angular项目代码规范从tslint改成eslint 日期:2024-01-11 栏目:计算机分类:1 人气:457 按照官方教程操作一般没有问题,可是我本地的环境用了npm最新版本,安装依赖的时候总是报错,只能手动安装eslint相关的依赖 [tslint更改为eslint官方教程](https://github.com/angular-eslint/angular-eslint/blob/main/docs/MIGRATING_FROM_TSLINT.md) 这样就面临一个问题,各个依赖之间的版本不好确定,如果安装最新版本,本地环境不兼容,如果安装推荐版本,对应依赖不确定,最后终于找到符合我的依赖,特别感谢**我爱学习** `@angular-eslint` `@typescript-eslint` `eslint`对应的依赖如下 ``` "devDependencies": { "@angular-eslint/builder": "12.7.0", "@angular-eslint/eslint-plugin": "12.7.0", "@angular-eslint/eslint-plugin-template": "12.7.0", "@angular-eslint/schematics": "12.7.0", "@angular-eslint/template-parser": "12.7.0", "@typescript-eslint/eslint-plugin": "4.28.2", "@typescript-eslint/parser": "4.28.2", "eslint": "^7.26.0", } ``` ### 鸣谢 - [我爱学习](https://www.5axxw.com/questions/content/b0iaei) 标签: angular eslint 上一篇:如何使用mvn命令导入依赖 下一篇:若依系统安装,配置和启动 随便看看 2024-02-19 PHP7 运算符“??” 和“?:”的区别 2022-11-30 Linux 后台运行命令 2022-11-25 关于我们 2022-11-30 centos一键系统安装lnmp集成环境 2022-11-30 linux 生成 ssh 公钥 留言