0.0.1-alpha.2 • Published 9 months ago

@142vip/eslint-config v0.0.1-alpha.2

Weekly downloads
-
License
MIT
Repository
github
Last release
9 months ago

@142vip/eslint-config

NPM version

介绍

本模块是在@antfu/eslint-config模块基础上封装的,可以自定义配置忽略文件校验规则,例如:

import { defineVipEslintConfig } from '@142vip/eslint-config'

export default defineVipEslintConfig({
  ignores: [
    '**/CHANGELOG.md',
  ],
  rules: {
    // 用于在模块构建后基于dist导出时找不到文件,忽略校验
    'antfu/no-import-dist': 1,
  },
})

同时,使用eslint:8.55.0版本,支持IDEA上配置使用

安装

# 下载模块
pnpm i @142vip/eslint-config -D

使用

在项目根目录中的package.json文件中,添加如下命令,校验项目,例如:

{
  "lint": "npx eslint .",
  "lint:fix": "npx eslint ."
}

也可以配合@142vip/fairy-cli模块,配置命令换成:

{
  "lint": "npx fa lint",
  "lint:fix": "npx fa lint --fix"
}

参考

证书

MIT

Copyright (c) 2019-present, 142vip 储凡

0.0.1-alpha.2

9 months ago

0.0.1-alpha.1

9 months ago

0.0.1-alpha.0

11 months ago