Skip to content

Commit

Permalink
Merge pull request #683 from eslint-functional/next
Browse files Browse the repository at this point in the history
close #599
close #678
fix #467
fix #576
fix #577
fix #611
fix #675
fix #691
fix #692
  • Loading branch information
RebeccaStevens authored Jul 30, 2023
2 parents ca1d1fa + 57e24d1 commit 103d3a4
Show file tree
Hide file tree
Showing 258 changed files with 8,641 additions and 7,251 deletions.
94 changes: 43 additions & 51 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,20 @@
"prettier"
],
"parserOptions": {
"project": [
"./tsconfig.json",
"./tests/tsconfig.json",
"./cz-adapter/tsconfig.json"
]
"project": true
},
"ignorePatterns": ["/build/", "/coverage/", "/lib/", "/cz-adapter/**/*.js"],
"ignorePatterns": [
"/build/",
"/coverage/",
"/lib/",
"/tests-compiled/",
"/cz-adapter/**/*.js"
],
"rules": {
"functional/prefer-immutable-types": "off"
"functional/prefer-immutable-types": "off",
"@typescript-eslint/no-explicit-any": "warn",
"@typescript-eslint/no-unnecessary-condition": "off",
"@typescript-eslint/restrict-plus-operands": "off"
},
"overrides": [
{
Expand Down Expand Up @@ -59,15 +64,26 @@
},
{
"files": ["**/*.test.ts"],
"plugins": ["ava"],
"extends": ["plugin:ava/recommended"],
"rules": {
"@typescript-eslint/no-unsafe-argument": "off",
"@typescript-eslint/no-unsafe-assignment": "off",
"@typescript-eslint/no-unsafe-call": "off",
"@typescript-eslint/no-unsafe-member-access": "off",
"@typescript-eslint/no-unsafe-return": "off",
"jsdoc/require-jsdoc": "off"
"@typescript-eslint/no-unused-vars-experimental": "off",
"@typescript-eslint/strict-boolean-expressions": "off",
"eslint-comments/disable-enable-pair": "off",
"eslint-comments/no-unlimited-disable": "off",
"functional/functional-parameters": "off",
"functional/no-conditional-statements": "off",
"functional/no-expression-statements": "off",
"functional/no-loop-statements": "off",
"functional/no-return-void": "off",
"import/no-named-as-default-member": "off",
"jsdoc/require-jsdoc": "off",
"sonarjs/no-duplicate-string": "off",
"sonarjs/no-identical-functions": "off",
"unicorn/prefer-module": "off"
}
},
{
Expand All @@ -84,64 +100,40 @@
"parserOptions": {
"project": null
},
"extends": ["plugin:markdown/recommended", "plugin:functional/off"],
"extends": [
"plugin:markdown/recommended",
"plugin:@typescript-eslint/disable-type-checked",
"plugin:functional/off"
],
"rules": {
"@typescript-eslint/await-thenable": "off",
"@typescript-eslint/consistent-type-definitions": "off",
"@typescript-eslint/dot-notation": "off",
"@typescript-eslint/explicit-member-accessibility": "off",
"@typescript-eslint/naming-convention": "off",
"@typescript-eslint/no-confusing-void-expression": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-floating-promises": "off",
"@typescript-eslint/no-for-in-array": "off",
"@typescript-eslint/no-implied-eval": "off",
"@typescript-eslint/no-misused-promises": "off",
"@typescript-eslint/no-throw-literal": "off",
"@typescript-eslint/no-unnecessary-condition": "off",
"@typescript-eslint/no-unnecessary-type-assertion": "off",
"@typescript-eslint/no-unsafe-argument": "off",
"@typescript-eslint/no-unsafe-assignment": "off",
"@typescript-eslint/no-unsafe-call": "off",
"@typescript-eslint/no-unsafe-member-access": "off",
"@typescript-eslint/no-unsafe-return": "off",
"@typescript-eslint/no-unused-expressions": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/non-nullable-type-assertion-style": "off",
"@typescript-eslint/prefer-includes": "off",
"@typescript-eslint/prefer-nullish-coalescing": "off",
"@typescript-eslint/prefer-readonly-parameter-types": "off",
"@typescript-eslint/prefer-readonly": "off",
"@typescript-eslint/prefer-regexp-exec": "off",
"@typescript-eslint/prefer-string-starts-ends-with": "off",
"@typescript-eslint/promise-function-async": "off",
"@typescript-eslint/require-await": "off",
"@typescript-eslint/restrict-plus-operands": "off",
"@typescript-eslint/restrict-template-expressions": "off",
"@typescript-eslint/strict-boolean-expressions": "off",
"@typescript-eslint/switch-exhaustiveness-check": "off",
"@typescript-eslint/unbound-method": "off",
"@typescript-eslint/prefer-function-type": "off",
"@typescript-eslint/consistent-generic-constructors": "off",
"import/no-unresolved": "off",
"init-declarations": "off",
"jsdoc/require-jsdoc": "off",
"no-console": "off",
"no-empty": "off",
"no-invalid-this": "off",
"no-undef": "off",
"no-useless-return": "off",
"node/handle-callback-err": "off",
"n/handle-callback-err": "off",
"prefer-const": "off",
"prettier/prettier": "off",
"sonarjs/no-extra-arguments": "off",
"sonarjs/no-unused-collection": "off",
"unicorn/prefer-optional-catch-binding": "off",
"unicorn/prefer-top-level-await": "off",
"unicorn/switch-case-braces": "off",

"dot-notation": "error",
"no-implied-eval": "error",
"require-await": "error"
"no-console": "off",
"no-empty": "off",
"no-invalid-this": "off",
"no-undef": "off",
"no-useless-return": "off",
"dot-notation": "off",
"no-empty-function": "off",
"no-throw-literal": "off",
"no-unused-vars": "off"
}
}
]
Expand Down
1 change: 0 additions & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
/.husky/** linguist-detectable=false

**/tsconfig.json linguist-language=jsonc
**/tsconfig.*.json linguist-language=jsonc
/.lintstagedrc linguist-language=json
/.vscode/*.json linguist-language=jsonc

Expand Down
3 changes: 2 additions & 1 deletion .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
issuehunt: eslint-functional/eslint-plugin-functional
tidelift: npm/eslint-plugin-functional
ko_fi: rebeccastevens
custom: https://github.com/eslint-functional/eslint-plugin-functional/blob/main/DONATIONS.md
issuehunt: eslint-functional/eslint-plugin-functional
7 changes: 7 additions & 0 deletions .github/workflows/sync-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,21 @@ on:
push:
branches:
- main
paths:
- .github/labels.yml
workflow_dispatch:

permissions:
pull-requests: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: micnncim/action-label-syncer@v1
with:
manifest: .github/labels.yml
env:
GITHUB_TOKEN: ${{ github.token }}
19 changes: 2 additions & 17 deletions .github/workflows/test-js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ jobs:
ts_version:
- "next"
- "latest"
- "4.0.2"
- "JS"
- "4.3.5"
# - "JS"
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.ts_version == 'next' }}
env:
Expand All @@ -47,21 +47,6 @@ jobs:
if: matrix.ts_version != 'JS'
run: pnpm add -D typescript@"${{ matrix.ts_version }}"

- name: Remove incompatible settings for ts 4.0.2
if: matrix.ts_version == '4.0.2'
run: |
node -e '
const fs = require("fs");
const filename = "./tsconfig.base.json";
const tsConfig = require(filename);
delete tsConfig.compilerOptions.exactOptionalPropertyTypes;
delete tsConfig.compilerOptions.noPropertyAccessFromIndexSignature;
delete tsConfig.compilerOptions.noUncheckedIndexedAccess;
const tsConfigString = JSON.stringify(tsConfig, undefined, 2);
fs.writeFileSync(filename, tsConfigString, { encoding: "utf8" });
console.log("TS Config updated successfully.");
'
- name: Run Tests
run: pnpm test-compiled

Expand Down
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
/lib/
/build/
/coverage/

.nyc_output/
/tests-compiled/

node_modules/

Expand Down
13 changes: 0 additions & 13 deletions .nycrc

This file was deleted.

3 changes: 1 addition & 2 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
/lib/
/build/
/coverage/

.nyc_output/
/tests-compiled/

node_modules/
pnpm-lock.yaml
Expand Down
2 changes: 1 addition & 1 deletion .releaserc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ plugins:
- changelogTitle: "# Changelog
All notable changes to this project will be documented in this file. Dates are displayed in UTC."
- - "@google/semantic-release-replace-plugin"
- - "semantic-release-replace-plugin"
- replacements:
- files:
- "./lib/**/*"
Expand Down
19 changes: 7 additions & 12 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,18 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "AVA Test Current Test File",
"program": "${workspaceFolder}/node_modules/ava/entrypoints/cli.mjs",
"args": ["${file}"],
"outputCapture": "std",
"skipFiles": ["<node_internals>/**/*.js"],
"env": {
"TEST_ALL_FILES": "1"
},
"name": "Debug Current Test File",
"autoAttachChildProcesses": true,
"skipFiles": ["<node_internals>/**", "**/node_modules/**"],
"program": "${workspaceRoot}/node_modules/vitest/vitest.mjs",
"args": ["run", "${relativeFile}"],
"smartStep": true,
"sourceMaps": true,
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
"console": "integratedTerminal"
}
]
}
1 change: 0 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"files.exclude": {
".nyc_output": true,
"coverage": true,
"cz-adapter/index.js": true
},
Expand Down
74 changes: 74 additions & 0 deletions CHANGELOG.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions DONATIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

Any donations would be much appreciated. 😄

## Enterprise Users

`eslint-plugin-functional` is available as part of the [Tidelift Subscription](https://tidelift.com/subscription/pkg/npm-eslint-plugin-functional?utm_source=npm-eslint-plugin-functional&utm_medium=referral&utm_campaign=enterprise&utm_term=repo).

## Real money

[![ko-fi](https://ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/rebeccastevens)
Expand Down
Loading

0 comments on commit 103d3a4

Please sign in to comment.