@foray1010/eslint-config 10.0.3 → 10.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,19 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [10.0.5](https://github.com/foray1010/common-presets/compare/@foray1010/eslint-config@10.0.4...@foray1010/eslint-config@10.0.5) (2023-03-24)
7
+
8
+ ### Bug Fixes
9
+
10
+ - **eslint-config:** add back [@typescript-eslint](https://github.com/typescript-eslint) eslint-recommended rules ([5355fac](https://github.com/foray1010/common-presets/commit/5355fac97bed3207ca11bf491f8438051081e647))
11
+
12
+ ## [10.0.4](https://github.com/foray1010/common-presets/compare/@foray1010/eslint-config@10.0.3...@foray1010/eslint-config@10.0.4) (2023-03-23)
13
+
14
+ ### Bug Fixes
15
+
16
+ - **eslint-config:** disable n/prefer-global hacks as they do not work with flat config ([4ede17d](https://github.com/foray1010/common-presets/commit/4ede17d93e403892bb731d1ad1900e19d03a8179))
17
+ - **eslint-config:** still have errors when using in project without typescript ([a20ae50](https://github.com/foray1010/common-presets/commit/a20ae50a71af5970ee69565f153a94c520cc944b))
18
+
6
19
  ## [10.0.3](https://github.com/foray1010/common-presets/compare/@foray1010/eslint-config@10.0.2...@foray1010/eslint-config@10.0.3) (2023-03-23)
7
20
 
8
21
  ### Bug Fixes
package/bases/base.mjs CHANGED
@@ -2,8 +2,6 @@ import js from '@eslint/js'
2
2
  import eslintPluginEslintComments from '@eslint-community/eslint-plugin-eslint-comments'
3
3
  // @ts-expect-error
4
4
  import { hasDep, isESM } from '@foray1010/common-presets-utils'
5
- import eslintPluginDeprecation from 'eslint-plugin-deprecation'
6
- import eslintPluginFunctional from 'eslint-plugin-functional'
7
5
  import eslintPluginImport from 'eslint-plugin-import'
8
6
  import eslintPluginJest from 'eslint-plugin-jest'
9
7
  import eslintPluginSimpleImportSort from 'eslint-plugin-simple-import-sort'
@@ -26,6 +24,10 @@ async function generateTypeScriptConfig() {
26
24
  ).default
27
25
  const typescriptEslintParser = (await import('@typescript-eslint/parser'))
28
26
  .default
27
+ const eslintPluginDeprecation = (await import('eslint-plugin-deprecation'))
28
+ .default
29
+ const eslintPluginFunctional = (await import('eslint-plugin-functional'))
30
+ .default
29
31
 
30
32
  return [
31
33
  {
@@ -54,7 +56,12 @@ async function generateTypeScriptConfig() {
54
56
  functional: eslintPluginFunctional,
55
57
  },
56
58
  rules: {
57
- ...eslintPluginTypescriptEslint.configs['eslint-recommended']?.rules,
59
+ ...eslintPluginTypescriptEslint.configs[
60
+ 'eslint-recommended'
61
+ ]?.overrides?.reduce(
62
+ (acc, override) => ({ ...acc, ...override.rules }),
63
+ {},
64
+ ),
58
65
  ...eslintPluginTypescriptEslint.configs['recommended']?.rules,
59
66
  ...eslintPluginTypescriptEslint.configs[
60
67
  'recommended-requiring-type-checking'
package/bases/node.mjs CHANGED
@@ -20,16 +20,6 @@ const nodeConfig = [
20
20
  plugins: {
21
21
  n: eslintPluginN,
22
22
  },
23
- languageOptions: {
24
- globals: {
25
- // hack to mute no-undef error, and show n/prefer-global/buffer error instead
26
- // @ts-expect-error
27
- Buffer: 'writable',
28
- // hack to mute no-undef error, and show n/prefer-global/process error instead
29
- // @ts-expect-error
30
- process: 'writable',
31
- },
32
- },
33
23
  rules: {
34
24
  // disallow deprecated node APIs
35
25
  'n/no-deprecated-api': 'error',
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package",
3
3
  "name": "@foray1010/eslint-config",
4
- "version": "10.0.3",
4
+ "version": "10.0.5",
5
5
  "homepage": "https://github.com/foray1010/common-presets/tree/master/packages/eslint-config#readme",
6
6
  "bugs": "https://github.com/foray1010/common-presets/issues",
7
7
  "repository": {
@@ -64,5 +64,5 @@
64
64
  "publishConfig": {
65
65
  "access": "public"
66
66
  },
67
- "gitHead": "11db51812a862318500928563f382138f8b5a9d6"
67
+ "gitHead": "f74fc1c607b33237dd85fede7b8f76f6d298dac6"
68
68
  }